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

Getting Started tutorial fails to find test #10338

Closed
goser opened this issue Jul 30, 2020 · 8 comments
Closed

Getting Started tutorial fails to find test #10338

goser opened this issue Jul 30, 2020 · 8 comments

Comments

@goser
Copy link

goser commented Jul 30, 2020

🐛 Bug Report

When following the getting started page step by step I get: No tests found, exiting with code 1

To Reproduce

Follow the steps on https://jestjs.io/docs/en/getting-started including yarn test

Expected behavior

Test success as described on https://jestjs.io/docs/en/getting-started

envinfo

System:
OS: Windows 10 10.0.17134
CPU: (12) x64 Intel(R) Core(TM) i7-8700 CPU @ 3.20GHz
Binaries:
Node: 12.14.1 - C:\Program Files\nodejs\node.EXE
Yarn: 1.21.1 - C:\Program Files (x86)\Yarn\bin\yarn.CMD
npm: 6.5.0 - C:\Program Files\nodejs\npm.CMD
npmPackages:
jest: ^26.2.1 => 26.2.1

I tried the same with jest@26.0.0 also not working.

jest@25.5.4 worked for me

@Radiateurs
Copy link

Radiateurs commented Jul 30, 2020

I have the same issue.
My jest.config.js is as follow :

module.exports = {
    verbose: true,
    collectCoverageFrom: [
        '<rootDir>/src/**/*.js',
        '!<rootDir>/node_modules/'
    ],
    testPathIgnorePatterns: [
        '<rootDir>/node_modules/'
    ],
    testMatch: [
        '**/__tests__/**/*.{js,jsx,mjs}',
        '**/+(*.)(spec|test).{js,jsx,mjs}'
    ]
};

Current file architecture :
/

|-> src/

|-> test/

|-> example.test.js

|-> package.json
|-> jest.config.jest

Could it be linked to #6546 ?

@jmtelljohann
Copy link

Are you sure it doesn't work in version 26.1.0? I just updated to 26.2.1 and Jest no longer finds my test (I use the default configuration for testMatch). If I downgrade to 26.1.0, it finds my tests again. It appears to be a Windows only issue because 26.2.1 finds my tests on Linux.

@ramram1048
Copy link

ramram1048 commented Jul 31, 2020

same issue for me, works on jest@25.5.4, not 26.1.0. my node version is v12.18.3

@goser
Copy link
Author

goser commented Jul 31, 2020

No luck with 26.1.0

@jmtelljohann
Copy link

jmtelljohann commented Jul 31, 2020

My issue was related to this and is fixed with 26.2.2: #10339

@github-actions
Copy link

This issue is stale because it has been open for 1 year with no activity. Remove stale label or comment or this will be closed in 30 days.

@github-actions github-actions bot added the Stale label Feb 17, 2023
@github-actions
Copy link

This issue was closed because it has been stalled for 30 days with no activity. Please open a new issue if the issue is still relevant, linking to this one.

@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Mar 19, 2023
@github-actions
Copy link

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Please note this issue tracker is not a help forum. We recommend using StackOverflow or our discord channel for questions.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 20, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants