-
-
Notifications
You must be signed in to change notification settings - Fork 6.5k
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
Jest won't run a specific test spec file from CLI #6014
Comments
Seeing as you're on windows, have you tried |
kindly include test match in the "jest":{"testMatch":[path that you wants to run]} of package.json. |
Wonder if this PR #5941 fixes it? You should be able to try this using |
This issue is stale because it has been open for 1 year with no activity. Remove stale label or comment or this will be closed in 30 days. |
This issue was closed because it has been stalled for 7 days with no activity. Please open a new issue if the issue is still relevant, linking to this one. |
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Do you want to request a feature or report a bug?
Bug report
What is the current behavior?
When I run all my test spec files together jest runs them all. But when I want to run a single spec file using 'jest path/to/my-test.js' I get the following error:
No tests found in C:\Users\User\Documents\folder12 files checked. testMatch: **/__tests__/**/*.js?(x),**/?(*.)(spec|test).js?(x) - 4 matches testPathIgnorePatterns: \\node_modules\\ - 12 matchesPattern: .\_tests_\API\tickers.spec.jS - 0 matches error An unexpected error occurred: "Command failed.Exit code: 1
Code structure:
tests
API
tickers.spec.js
What is the expected behavior?
tickers.spec.js should run
Run
npx envinfo --preset jest
in your project directory and paste theresults here
System:
OS: Windows 10
CPU: x64 Intel(R) Core(TM) i7-5600U CPU @ 2.60GHz Binaries: Yarn: 1.5.1 - C:\Program Files (x86)\Yarn\bin\yarn.CMD
npm: 5.6.0 - C:\Program Files\nodejs\npm.CMD
The text was updated successfully, but these errors were encountered: