Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test suite failed to run on with-jest example #5144

Closed
randalmaia opened this issue Sep 12, 2018 · 0 comments · Fixed by #5149
Closed

Test suite failed to run on with-jest example #5144

randalmaia opened this issue Sep 12, 2018 · 0 comments · Fixed by #5149

Comments

@randalmaia
Copy link

Examples bug report

Example name

with-jest

Describe the bug

Test suite failed to run

npm run test

> [email protected] test /Users/randalmaia/Code/next.js/examples/with-jest
> NODE_ENV=test jest

 FAIL  __tests__/index.test.js
  ● Test suite failed to run

    Plugin 0 specified in "/Users/randalmaia/Code/next.js/examples/with-jest/node_modules/next/babel.js" provided an invalid property of "default" (While processing preset: "/Users/randalmaia/Code/next.js/examples/with-jest/node_modules/next/babel.js")

      at Plugin.init (node_modules/jest-config/node_modules/babel-core/lib/transformation/plugin.js:131:13)
          at Array.map (<anonymous>)
          at Array.map (<anonymous>)

Test Suites: 1 failed, 1 total
Tests:       0 total
Snapshots:   0 total
Time:        1.445s
Ran all test suites.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] test: `NODE_ENV=test jest`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the [email protected] test script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/randalmaia/.npm/_logs/2018-09-12T11_20_40_999Z-debug.log

To Reproduce

  • Clone the next.js repository
    git clone [email protected]:zeit/next.js.git
  • Go to the example folder
    cd next.js/examples/with-jest
  • Install the npm
    npm i
  • Try run tests
    npm run test

Expected behavior

Should run the tests with success

Screenshots

screen shot 2018-09-12 at 8 13 08 am

System information

  • OS: OSX
  • Version of Next.js: latest

Additional context

I read this issue #4227 and tried the solutions without success

@lock lock bot locked as resolved and limited conversation to collaborators Sep 12, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant