Unit Test In React Native Using Jest

suggest change

Starting with React Native 0.38, react-native init adds a Jest setup. This configuration should already be in your package.json:

"scripts": {
"start": "node node_modules/react-native/local-cli/cli.js start",
"test": "jest"
},
"jest": {
 "preset": "react-native"
}

Run npm test or jest. For a full sample, see the Jest React Native example.

Feedback about page:

Feedback:
Optional: your email if you want me to get back to you:



Table Of Contents