Skip to content
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

jsdom environment #67

Open
joshkel opened this issue Jan 21, 2023 · 0 comments
Open

jsdom environment #67

joshkel opened this issue Jan 21, 2023 · 0 comments

Comments

@joshkel
Copy link

joshkel commented Jan 21, 2023

I'm guessing that this falls under "Unsupported Jest features", but I want to confirm:

Our project contains a mix of front-end (React) and generic (business logic) code, so we let Jest use its default node environment then configure individual test cases to use JSDom via @jest-environment jsdom docblocks. This is faster than initializing JSDom everywhere.

In a brief experiment with jest-light-runner, I saw that these tests are failing. I assume that, because jest-light-runner doesn't use vm to isolate tests, it doesn't support @jest-environment docblocks and must run every test in the same environment?

Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant