-
Notifications
You must be signed in to change notification settings - Fork 29.7k
Description
Currently all of the CI test filtering is based on packages changed. This helps a lot, but there are categories of changes within a package where we run a lot of tests that we could easily determine to be unnecessary. It would be useful to add a generic utility to the command system in the repo tooling where commands could explicitly list files that cannot affect their output (the reverse would be simpler, but would be much more likely to accidentally not run tests, and we want to minimize the possibility of that).
Some obvious examples:
- README.md changes can only affect README validations.
- CHANGELOG.md changes can only affect changelog/version validations.
- pubspec.yaml changes that only affect the version line (we'll need to special-case this, but if we don't the whole system would be pretty pointless since almost all changes bump the version) only affect version and pubspec validations.
- test/*.dart test changes can't affect integration tests or native tests.
- integration_test/*.dart changes can't affect native unit tests or Dart unit tests
The generic support would take a list from the command and validate it against every changed file, and then skip tests for any package where everything matched.
We could skip expensive tests like integration tests for all of those cases.