You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
won't resolve and test fails by timeout with error:
thrown: "Exceeded timeout of 5000 ms for a test.
Add a timeout value to this test to increase the timeout, if this is a long-running test. See https://jestjs.io/docs/api#testname-fn-timeout."
Additional context
I noticed that in @testing-library/user-event library there is some code like this:
FWIW, I think this is a testing-library issue, not a jest one. I have opened an issue with the relative explanation and possible fixes in: testing-library/dom-testing-library#1286 .
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.
Please note this issue tracker is not a help forum. We recommend using StackOverflow or our discord channel for questions.
Version
29.7.0
Steps to reproduce
npm run test
Expected behavior
Tests done
Actual behavior
line
won't resolve and test fails by timeout with error:
Additional context
I noticed that in
@testing-library/user-event
library there is some code like this:config.advanceTimers
is option - https://testing-library.com/docs/user-event/options/#advancetimersThis promise resolves as expected but in test there is no resolve or reject, it just freezes.
I think this is because fake timers affects microtasks mechanism or something else.
Environment
The text was updated successfully, but these errors were encountered: