Fix warning message when there are no tests#8595
Fix warning message when there are no tests#8595SimenB merged 4 commits intojestjs:masterfrom kaykayehnn:fix-pass-with-no-tests-warning
Conversation
Codecov Report
@@ Coverage Diff @@
## master #8595 +/- ##
==========================================
- Coverage 63.24% 63.22% -0.03%
==========================================
Files 272 272
Lines 11312 11316 +4
Branches 2761 2762 +1
==========================================
Hits 7154 7154
- Misses 3541 3544 +3
- Partials 617 618 +1
Continue to review full report at Codecov.
|
thymikee
left a comment
There was a problem hiding this comment.
Nice! Can you add a changelog entry and a small test?
|
Sure! I added a changelog entry and some snapshot tests. While adding the tests I found a simpler way to fix the issue so I'll have to force push the new changes. |
|
This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Summary
When running jest with '--passWithNoTests' but there are no tests to execute, it prints a superfluous warning. This PR removes this warning.
Description
In both screenshots below there are no test files and jest is executed with
--passWithNoOptions.It used to log that it exited with code 1 and a message to use
--passWithNoOptions, while it exits with code 0 and the option is already provided.Closes #8594
Before:

After:
