-
-
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
before handlers timing out looks like the test timing out #8284
Comments
Can you test this with circus? We've changed how failures in hooks like See installation instructions in its readme: https://yarnpkg.com/en/package/jest-circus |
Seems like the problem persists in circus:
|
To run scripts with npm, you need an extra |
Ah, good point. Here's the proper invocation:
If |
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 30 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. |
🐛 Bug Report
When a
beforeAll
takes longer than its default timeout, the resulting error message looks hard to distinguish from the test itself timing out. I was debugging a failing test and kept increasing its timeout, when in fact what was causing the failure was thebeforeAll
function occasionally taking longer than 5 seconds to setup.To Reproduce
Run the repl. The error with the current version of Jest is verbose but as helpful as it could be:
Expected behavior
Jest should inform the developer that the beforeAll() function timed out.
Link to repl or repo (highly encouraged)
https://repl.it/repls/KnowingGenerousCommas
Run
npx envinfo --preset jest
Paste the results here:
The text was updated successfully, but these errors were encountered: