-
-
Notifications
You must be signed in to change notification settings - Fork 26.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
npm test does not honour Jest settings when the CI environment variable is set. #9338
Comments
Files matching watchPathIgnorePatterns should be not ignored when running in CI mode. They are only ignored when running in watch mode so this seems to be running correctly to me. Read the docs in the link to find out more. |
I checked your link. Where does it say anything about CI mode? As far as I see, CI mode is not mentioned at all there. |
The link is for the parameter |
Ah sorry I was confused, I did not get the meaning of "watch mode" before. I assumed that "watching" meant file watching in general, even when in CI mode. My fault. I also found testPathIgnorePattern. I guess I should open an issue for supporting this in create-react-app. Thanks eddiemonge for pointing me in the right direction, despite my ignorance. |
I opened a new issue concerning |
Describe the bug
npm test
does not honour Jest settings when the environment variableCI
is set.Did you try recovering your dependencies?
Yes, I did a
and
npm --version
says6.14.6
.The problem still exists.
Environment
Steps to reproduce
Have the follwoing jest settings in
package.json
Run
All tests succeed and files like
App.testcases.ts
are excluded from test.Run
All previous tests succeed, but the overall process fails, because files like
App.testcases.ts
are NOT excluded from test.Expected behavior
Independent of the
CI
environment variable,npm test
should honour the jest settings inpackage.json
.Actual behavior
Test output:
I.e., if the
CI
environment variable is set,npm test
ignores the jest settings inpackage.json
.Reproducible demo
An almost out-of-the-box app:
https://github.com/svdHero/react-ci-test
The text was updated successfully, but these errors were encountered: