How to filter the tests that mutants run against? #1691
-
Hi, I am trying out Stryker, and I am wondering how I can limit what test cases run in a test run. In my case I have created a new feature in code, which has some tests that I (on their own) would like to catch all mutants in a specific subset of the code. In the configuration file I can (i think) use "mutate" to limit what files are mutated, but I do not see how to also limit the test cases that are executed? (considered that this test assembly has ~1000 tests) |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
By default stryker will only run unit tests that cover the enabled mutants, so if you use mutate to limit the scope of the mutants to test, your unit tests should also be scoped to those mutants. Sometimes we can't determine the scope of a unit test, and then that unit test will also be included in the set. In V1 there will also be a new feature where you can pass a testfilter to stryker, but that shouldn't be neccesary for your usecase. |
Beta Was this translation helpful? Give feedback.
By default stryker will only run unit tests that cover the enabled mutants, so if you use mutate to limit the scope of the mutants to test, your unit tests should also be scoped to those mutants. Sometimes we can't determine the scope of a unit test, and then that unit test will also be included in the set.
In V1 there will also be a new feature where you can pass a testfilter to stryker, but that shouldn't be neccesary for your usecase.