-
-
Notifications
You must be signed in to change notification settings - Fork 6.6k
Description
This is a feature request.
I currently have a setup that involves jest tests asyncronously creating and re-aliasing elasticsearch indices and part of their setup and tear down routines.
The tests run perfectly fine if I specify jest --runInBand on the command line.
If I run them without --runInBand I get random test failures due to the inherent race conditions with running these tests asynchronously.
What I would like is an option in package.json:
{
"jest": {
"runInBand": true
}
}
Such that the flag is automatically applied to jest (like all the other package.json settings), without needing to manually specify it on the command line each time.
The lack of this feature may potentially confuse other developers on my team who attempt to run the jest tests without being explicitly aware the tests are dependent on the --runInBand flag being present, thus observing a broken test suite.
package.json is the correct place to document this configuration dependancy
Thank you.