dimanche 28 avril 2019

JEST testing, getting error on import of configure from enzyme

I'm trying to run my tests in repo here: https://github.com/Futuratum/moon.holdings

But I'm getting the following error

/Users/leongaban/projects/Futuratum/moon.holdings/jest.config.js:1 (function (exports, require, module, __filename, __dirname) { import { configure } from 'enzyme'

My tests use to work and I haven't changed anything, so curious as to what could be causing this problem?

My jest.config.js file looks correct:

import { configure } from 'enzyme'
import Adapter from 'enzyme-adapter-react-16'

configure({ adapter: new Adapter() })

package.json

"scripts": {
  "dev": "next -p 7777",
  "build": "next build",
  "start": "next -p 7777",
  "test": "NODE_ENV=test jest --watch --no-cache",
  "test-win": "SET NODE_ENV=test&& jest --watch"
},

enter image description here

Aucun commentaire:

Enregistrer un commentaire