jest icon indicating copy to clipboard operation
jest copied to clipboard

[Bug]: collectCoverageFrom not working for react components

Open stoplion opened this issue 3 years ago • 0 comments

Version

26.6.0

Steps to reproduce

Add to package.json

....
"jest": {
    "collectCoverageFrom": [
      "src/**/*.ts,tsx}",
      "!src/**/*.d.ts"
    ]
  },

have some folders like:

src/components/header/index.tsx

those files are not included in the output table

Expected behavior

React testing library would include coverage reports for React component when the globbed..

Actual behavior

React component do not show up in cov report

Additional context

No response

Environment

System:
    OS: macOS 12.3
    CPU: (10) arm64 Apple M1 Max
  Binaries:
    Node: 16.16.0 - /usr/local/bin/node
    Yarn: 1.22.0 - ~/.yarn/bin/yarn
    npm: 8.11.0 - /usr/local/bin/npm

stoplion avatar Aug 05 '22 21:08 stoplion

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

github-actions[bot] avatar Sep 04 '22 21:09 github-actions[bot]