We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
If __DEV__ is truthy, React injects a large number of additional elements which interfere with tests.
__DEV__
There is therefore a hack which sets this to false at the top of the Jest helper:
(global as unknown as { __DEV__: boolean }).__DEV__ = false;
This is supposedly derived from NODE_ENV not being production, but applying this change breaks all other tests:
NODE_ENV
production
act(...) is not supported in production builds of React, and might not behave as expected.
Is there a better way of resolving this problem?
The text was updated successfully, but these errors were encountered:
No branches or pull requests
If
__DEV__
is truthy, React injects a large number of additional elements which interfere with tests.There is therefore a hack which sets this to false at the top of the Jest helper:
This is supposedly derived from
NODE_ENV
not beingproduction
, but applying this change breaks all other tests:Is there a better way of resolving this problem?
The text was updated successfully, but these errors were encountered: