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

Tests script crush after start #7

Open
Akiyamka opened this issue Jan 26, 2020 · 1 comment
Open

Tests script crush after start #7

Akiyamka opened this issue Jan 26, 2020 · 1 comment

Comments

@Akiyamka
Copy link
Contributor

After i try run test script it's fails.

➜ yarn test
yarn run v1.21.1
$ jest
● Validation Error:

  Preset jest-preset-preact not found.
@Akiyamka
Copy link
Contributor Author

Akiyamka commented Jan 26, 2020

Reason of this bug - outdated version of jest-config package.
I upgrade jest package up to ^25.1.0, removing yarn.lock and reinstall all deps for fix that.
After that jest starts, and run first test.
But now first test crush with another error

➜ yarn test
yarn run v1.21.1
$ jest
 FAIL  tests/header.test.js
  ● Test suite failed to run

    TypeError: createConfig is not a function

      at Object.<anonymous> (node_modules/jest-preset-preact/src/babel-jest.js:4:16)
      at ScriptTransformer._getTransformer (node_modules/@jest/transform/build/ScriptTransformer.js:335:19)
      at ScriptTransformer.transformSource (node_modules/@jest/transform/build/ScriptTransformer.js:410:28)
      at ScriptTransformer._transformAndBuildScript (node_modules/@jest/transform/build/ScriptTransformer.js:522:40)

Test Suites: 1 failed, 1 total
Tests:       0 total
Snapshots:   0 total
Time:        0.53s
Ran all test suites.
error Command failed with exit code 1.

Look like i need update something else, but i not understand what exactly.
Mayby related issue: preactjs/preact-cli#892

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant