feature: adding smarter unit test execution - #5966
Conversation
Signed-off-by: Cortland Goffena <30168413+cmgoffena13@users.noreply.github.com>
Signed-off-by: Cortland Goffena <30168413+cmgoffena13@users.noreply.github.com>
Signed-off-by: Cortland Goffena <30168413+cmgoffena13@users.noreply.github.com>
…ow too Signed-off-by: Cortland Goffena <30168413+cmgoffena13@users.noreply.github.com>
| default=None, | ||
| ) | ||
| @click.option( | ||
| "--all-tests", |
There was a problem hiding this comment.
Most of the other flags are verb_*. should this be --include_all_tests, or something similar?
|
Nice idea! I do worry about the default behavior being only running impacted model's unit tests. An indirect model change could take place (i.e., things like a SQLGlot upgrade changing rendering/types, or an engine adapter change) and then tests would fail silently for a long time before it's caught. Also, would be good to add a console output |
|
@mday-io -- yeah, now that I have time to think about it, I think it would make more sense to flip the logic I have and maybe add a flag for smarter unit test execution, thoughts? That way we wouldn't change default behavior and its opt-in. I like the Skipped X tests as well. Just need to think of what the flag would be called. Maybe |
|
yeah, I think that's the safest option for now. and, what about |
Description
During
plan, run unit tests only for models in the plan change set (added, modified, restated).No-change plans skip tests by default.
--all-testsruns the full suite (previous default).Addresses #5965
Test Plan
--all-testsruns the full suite (including no-change plans)--skip-testsstill skips; incompatible with--all-tests--all-testsChecklist
make styleand fixed any issuesmake fast-test)git commit -s) per the DCO