No coverage report for JSX file
See original GitHub issueLink to bug demonstration repository
https://github.com/Quoin/react-utils/tree/master/src
Expected Behavior
I expect to see code coverage for the JSX file
Observed Behavior
The test output the test for the JSX file (in this case error-boundary.jsx
), but in the coverage report, I don’t see it. It is neither in the summary nor in the html output. (reports/coverage/index.html
).
I know the test is run because of this output:
src/error-boundary
✓ should be a function with 1 param
Troubleshooting steps
-
still occurring when I put
cache: false
in my nyc config -
npm ci
-
npm run coverage && npm run coverage-report
Environment Information
# paste the output here
System:
OS: macOS 10.15.1
CPU: (8) x64 Intel(R) Core(TM) i7-4870HQ CPU @ 2.50GHz
Memory: 551.17 MB / 16.00 GB
Binaries:
Node: 8.12.0 - ~/.nvm/versions/node/v8.12.0/bin/node
Yarn: 1.19.2 - /usr/local/bin/yarn
npm: 6.13.2 - ~/.nvm/versions/node/v8.12.0/bin/npm
npmPackages:
@babel/cli: ~7.7.5 => 7.7.5
@babel/core: ~7.7.5 => 7.7.5
@babel/preset-env: ~7.7.6 => 7.7.6
@babel/preset-react: ~7.7.4 => 7.7.4
@babel/register: ~7.7.4 => 7.7.4
nyc: ~14.1.1 => 14.1.1
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
Coverage report not working · Issue #7838 - GitHub
I should see the coverage report including the App.js file. Actual behavior. I see no file included in the report: image. Reproducible demo....
Read more >Code coverage on JSX tests with Istanbul - Stack Overflow
My tests use the babel-rewire-plugin , and gulp-jsx-coverage was not instrumenting my files correctly, resulting in a coverage report that included a bunch ......
Read more >Code coverage not shown in the UI for Javascript application
Hello, I try to analyse a React Native project with Sonarcloud. ... The analysis works well but I do not have any coverage...
Read more >Running Tests | Create React App
Coverage Reporting . Jest has an integrated coverage reporter that works well with ES6 and requires no configuration. Run npm test -- --coverage...
Read more >Running tests and creating code coverage reports for React ...
I originally wanted to have the code coverage report parsed by JaCoCo so the Jenkins job list can show the total number of...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
This is just the way github and npm work. Development happens on github, releases are published to npm. This is not something I can solve without unacceptable burden on the release process.
Oh, I see. Sorry, I was expecting master to be the official version (because it is said:
npm i -D nyc
which installlatest
) instead of a next version. My bad.Would be great that version is displayed at the top of the README, and have links to older versions (create a branch from your latest tag 14.1.1). That would be really helpful instead of relying on external (
npmjs
).Thanks,