Question
Hello ๐
First, thank you for this great library ๐
After reading the documentation, I didn't find a way to execute a custom command to run tests ๐ Basically when I run :
npx stryker run it uses npm test under the hood for running tests.
How can I customize the command to execute for running tests ?
For example let's say I want to ignore my integration tests, and want to run mutation testing only for unit tests, in this case I would like to execute the command npm run jest src/**/__unit_tests__/*.spec.ts
Thanks !
Stryker environment
"@stryker-mutator/core": "3.3.1",
"@stryker-mutator/jest-runner": "3.3.1",
"@stryker-mutator/typescript": "3.3.1",
"jest": "26.4.2",
"ts-jest": "26.4.1",
Additional context
You can use
{
"commandRunner": {
"command": "jest src/**/__unit_tests__/*.spec.ts"
}
}
I guess it is not yet documented. Sorry for that.
Thanks for the answer @nicojs , it works perfectly ๐ If you want I can create a PR to update the documentation ๐
Probably here https://github.com/stryker-mutator/stryker/blob/master/packages/core/README.md#configuration ?
Yes!!! Thank you!
@nicojs Done https://github.com/stryker-mutator/stryker/pull/2522 โ