You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Cannot get jest to run on my react-native project.
When trying to set up jest on react-native project, the following error occurred:
<project_root>\node_modules\react-native\Libraries\polyfills\error-guard.js:14
type ErrorHandler = (error: mixed, isFatal: boolean) => void;
^^^^^^^^^^^^
SyntaxError: Unexpected identifier
at Runtime._execModule (node_modules/jest-runtime/build/index.js:1157:58)
at Object.<anonymous> (node_modules/react-native/jest/setup.js:16:6)
It appears my jest runs react-native's jest/setup.js. and can't compile it's dependancy because of 'type' (flow keyword).
To Reproduce
Steps to reproduce the behavior:
I'm using jest-expo (version 42.0.1) with babel-jest, and added babel-plugin-transform-flow-strip-types as described here
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.
Please note this issue tracker is not a help forum. We recommend using StackOverflow or our discord channel for questions.
🐛 Bug Report
Cannot get jest to run on my react-native project.
When trying to set up jest on react-native project, the following error occurred:
It appears my jest runs react-native's
jest/setup.js
. and can't compile it's dependancy because of 'type' (flow keyword).To Reproduce
Steps to reproduce the behavior:
I'm using jest-expo (version 42.0.1) with babel-jest, and added
babel-plugin-transform-flow-strip-types
as described heremy jest configuration in
package.json
:my
babel.config.js
:envinfo
The text was updated successfully, but these errors were encountered: