-
-
Notifications
You must be signed in to change notification settings - Fork 3.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
Test fail with provider in react-native #2137
Comments
We updated React-Redux's packaging in v9, and it should be using ESM modules by default. Our tests show it should work with Jest. If you have a specific issue, please provide a repo that shows this error happening so we can investigate. |
I created a repo : https://github.com/salarmiirzaeie/react-redux-jest/tree/main |
You don't have
|
I have the same problem. Adding this to config doesn't help |
This has helped #2103 (comment) |
What version of React, ReactDOM/React Native, Redux, and React Redux are you using?
What is the current behavior?
When we was trying test components using jest and redux in react-native, it said "SyntaxError: Cannot use import statemen outside a module" where we used Provider from react-redux in version 9.1.0 but in react-redux version 8.1.3 it was passed in jest
What is the expected behavior?
It should pass in version 9.1.0 like other version like v 8.13
Which browser and OS are affected by this issue?
No response
Did this work in previous versions of React Redux?
The text was updated successfully, but these errors were encountered: