Skip to content

Unit tests are not executed #2889

@jurosh

Description

@jurosh

Is this a bug report?

Yes

Can you also reproduce the problem with npm 4.x?

I am using latest yarn 0.27.5 and npm 5.2.0 on Windows.

Environment

  • Node 8.1.3
  • Yarn 0.27.5 or NPM 5.2.0
  • react-scripts@1.0.1
  • Windows

Steps to Reproduce

  1. Run yarn test or npm test (is running script react-scripts test --env=jsdom)

  2. It says: "Determining test suites to run..." -> "Press a to run all tests."

  3. After hitting a

  4. You see:

No tests found
In C:\PROJECT
  18490 files checked.
  testMatch: C:\PROJECT\src\**\__tests__\**\*.js?(x),C:\PROJECT\src\**\?(*.)(spec|test).js?(x) - 6 matches
  testPathIgnorePatterns: \\node_modules\\ - 18490 matches
Pattern: "" - 0 matches

No tests were executed but there are tests inside in PROJECT/src/ eg. default App.test.js - these tests are being executed when saving changes while in jest watch mode.

Expected Behavior

All tests inside src/**/*.test.js should be executed

Note (Temporary workaround)

Using Windows 10 bash (ubuntu) it's running fine, so looks like it affects only Windows (tested on both - Win 7 & 10)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions