Skip to content

Commit

Permalink
Fix jest-preset to use internal preprocessor instead of plain babel-j…
Browse files Browse the repository at this point in the history
…est (should fix facebook#19859)

By unknown reason babel-jest can't transform tests and react-native's files, see facebook#19859 for details. But internal preprocessor.js can, so use it for now in published jest-preset.json.
  • Loading branch information
vovkasm committed Jul 6, 2018
1 parent 0f49265 commit cdc3e8c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion jest-preset.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"<rootDir>/node_modules/react-native/Libraries/react-native/"
],
"transform": {
"^.+\\.js$": "babel-jest",
"^.+\\.js$": "<rootDir>/node_modules/react-native/jest/preprocessor.js",
"^.+\\.(bmp|gif|jpg|jpeg|mp4|png|psd|svg|webp)$": "<rootDir>/node_modules/react-native/jest/assetFileTransformer.js"
},
"transformIgnorePatterns": [
Expand Down

0 comments on commit cdc3e8c

Please sign in to comment.