-
-
Notifications
You must be signed in to change notification settings - Fork 6.4k
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 hangs indefinitely using external jsdom #2288
Comments
I don't think this is a Jest issue. We don't have any issues with jsdom starting to hang with thousands of tests, so it may be your test code. Is there a reason you cannot use Jest's provided jsdom environment? |
Is there a way to use jsom's internal calls ( |
no, we don't expose those. It may be that your test is not cleaning up old instances of jsdom properly if you can only use 12 instances of jsdom. |
it happens also with onlt one instance when I'm not passing |
Yeah, there might be some issue somewhere but it isn't really something we actively support so we'll have to rely on your pull requests to help us out :) |
understood, I'll try to find out that somewhere (if any) asap ;) |
@EnoahNetzach, recently has a problem when jest hangs after even |
Thanks @Nitive, but for other tests it works just fine, and there is a "hard wired" number of tests it correctly handles (12), so I don't think it's a watchman problem. |
I've got a similar issue |
Jest has detected the following 1 open handle potentially keeping Jest from exiting: ● PROMISE
|
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?
A bug.
What is the current behavior?
Running tests with
jsdom.jsdom(undefined, { url: URL })
hangs indefinitely.If the CLI var
--env=jsdom
is provided, the number of tests in one single file that can usejsdom
grows to ~12 (but this could be machine-dependent), but adding one additional test makes it hang once again.If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal repository on GitHub that we can
npm install
andnpm test
.git clone https://github.com/EnoahNetzach/jsdom-server-test
, then follow the instructions on its README.A real-life example is facebook/create-react-app#1187.
What is the expected behavior?
It shouldn't hang.
Run Jest again with
--debug
and provide the full configuration it prints. Please mention your node and npm version and operating system.uname -mrs
:Linux 4.8.8-200.fc24.x86_64 x86_64
npm --version
:3.10.8
node --version
:v6.9.1
I'm not entirely sure this is a jest bug.
It could be a jsdom one, although I can reproduce this only with jest.
The text was updated successfully, but these errors were encountered: