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
I am using the ignite boilerplate and I just want to point out that you shouldn't delete the .babelrc file when replacing its content with babel-transformer.js!
Doing this leads to Jest tests stop working due to the ES6 code of the tests not being recognized properly. You get the dreaded:
FAIL Tests/Sagas/StartupSagaTest.js
● Test suite failed to run
/home/myself/MyProject/Tests/Sagas/StartupSagaTest.js:1
({"Object.<anonymous>":function(module,exports,require,__dirname,__filename,global,jest){import { select, put } from 'redux-saga/effects';
^^^^^^
SyntaxError: Unexpected token import
at ScriptTransformer._transformAndBuildScript (node_modules/jest-runtime/build/ScriptTransformer.js:289:17)
at handle (node_modules/worker-farm/lib/child/index.js:44:8)
at process.<anonymous> (node_modules/worker-farm/lib/child/index.js:51:3)
at emitTwo (events.js:125:13)
I did delete the .babelrc and it took me a ton of time to find the issue. Now I have this .babelrc in the root of the project:
I am using the ignite boilerplate and I just want to point out that you shouldn't delete the
.babelrc
file when replacing its content withbabel-transformer.js
!Doing this leads to Jest tests stop working due to the ES6 code of the tests not being recognized properly. You get the dreaded:
I did delete the .babelrc and it took me a ton of time to find the issue. Now I have this
.babelrc
in the root of the project:And add
NODE_ENV=test
to the test task inpackage.json
.The text was updated successfully, but these errors were encountered: