-
-
Notifications
You must be signed in to change notification settings - Fork 26.9k
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
TypeError: TestEnvironment is not a constructor in combination with Enzyme #546
Comments
Can you give the exact test code that is failing please? |
Interesting. At first I couldn’t reproduce this but after stopping and starting the watcher again I’m getting this even with an empty test file. Console output:
cc @cpojer |
Sure, you can easily recreate the error by creating a new (0.3.0) project:
This throws:
Even running an empty test is throwing this error, but for completeness:
|
Apparently
|
I fixed this locally by commenting these lines out. In case of Create React App it is incorrect to resolve relative to |
We’re going to cut a patch fixing this today but for now, you can work around it by opening |
With Enzyme installed, running tests:
Throws the error:
The tests run correctly when removing
--env=jsdom
.The text was updated successfully, but these errors were encountered: