jeudi 27 décembre 2018

Unecpected token { in Jest testing

I'm starting to learn Jest testing framework, and trying to do simple test by using npm test, but I have this error:

enter image description here

I am trying ot change import to require, but it's not help :( any suggestions about how can I handle this error?

Also here is my package.json file part, that related to devDependencies and jest: { "devDependencies": { "babel-core": "^6.26.3", "babel-preset-env": "^1.6.1", "babel-preset-es2015": "^6.24.1", "babel-preset-react": "^6.24.1", "jest": "^22.4.3", "parcel-bundler": "^1.11.0" }, "jest": { "verbose": true, "testURL": "http://localhost:1234/" } }

Aucun commentaire:

Enregistrer un commentaire