AryaKetanShCt commented on PR #42850:
URL: https://github.com/apache/superset/pull/42850#issuecomment-5213312554

   Addressed the coverage report as well.
   
   Patch coverage was 33% because the flags Codecov aggregates (`python`, 
`postgres`, `mysql`, …) come from the **integration** suite, and my tests were 
unit-only — the `unit` flag shows `<ø>`, so none of the new lines were 
attributed. The validator was tested, just not by anything Codecov was 
measuring.
   
   Added `test_create_report_schedule_slack_v2_requires_channel_id` to 
`tests/integration_tests/reports/api_tests.py`, which drives the real `POST 
/api/v1/report/` path:
   
   - a channel name → 400, and the message names the offending value
   - a mixed `id,name` target → 400, naming only the bad part
   - an empty target → 400
   - two channel ids → 201
   - deprecated `Slack` v1 with a channel name → **201**, pinning the carve-out 
at the API layer as well as the schema layer
   
   That last case is worth having in the integration suite specifically, since 
three existing tests in this file already create v1 recipients with `{"target": 
"channel"}` and must keep passing.
   
   The unit tests stay as they are — they cover the branch logic cheaply; the 
integration test covers the wiring and the coverage flags.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to