-
-
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 not showing skipped tests and throws if testNamePattern does not match any test #6584
Comments
Any update on this? |
Can reproduce on Jest master. Somebody:tm: should bisect |
This looks pretty similar to #6415. Also, I fixed |
I did a bisect, it was introduced by this PR #6234. The regression is only present in jest-jasmine2, it works fine with JEST_CIRCUS=1 cc: @rickhanlonii @SimenB |
@jbdemonte thoughts? |
need to dig... |
I guess this pull request will fix it |
Closing via #6657 |
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. |
💥 Regression Report
I need to discover the test case names before executing them. I use the configuration option testNamePattern with value
^$a
which will not match any string and hence cause jest to skip all tests. I use a custom reporter to check the test case names. After updating jest to latest version, using this test pattern and running jest I get this error.Another regression, if a testNamePattern matches some tests in one suite and no tests in another suite, the unmatched tests are not reported as skipped. Consider 4 test cases in the same file
suite a > test 1
,suite a > test 2
,suite b > test 1
andsuite b > test 2
The two test cases in
suite a
match and are executed. Test cases forsuite b
don't match and are not shown as skipped.Last working version
Worked up to version: 22.4.3
Stopped working in version: 23.2.0
To Reproduce
Run jest with config
and
Expected behavior
For
"testNamePattern": "^$a"
For
"testNamePattern": "suite a"
Link to repl or repo (highly encouraged)
I see that repl.it is running jest v22.1.2 and the output is as expected, but here it is anyway for the sake of this issue not being stalled: https://repl.it/repls/WideeyedFrayedTerabyte
Run
npx envinfo --preset jest
The text was updated successfully, but these errors were encountered: