question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Support Jest coverageThreshold option

See original GitHub issue

I would like to configure the coverage threshold from jest to be able to launch jenkins from CI with a 90-100% coverage. Can we have support for this in Create react app ?

What is the most relevant:

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Reactions:10
  • Comments:12 (8 by maintainers)

github_iconTop GitHub Comments

5reactions
devillexiocommented, Dec 8, 2016

Jest configurability would be excellent, thanks!

For now, this is how we achieve coverage threshold checking on CI:

"coverage": "CI=true npm t -- --coverage",
"postcoverage": "istanbul check-coverage --statements 90 --functions 90 --branches 90 --lines 90",
2reactions
gaearoncommented, Nov 20, 2016

@gaelduplessix We intend to add some configurability in the future. I’m not closing the issue but now is not the time yet. Perhaps in a few months when more things shake out (e.g. Jest has been going through a ton of changes recently).

Read more comments on GitHub >

github_iconTop Results From Across the Web

Configuring Jest
coverageThreshold [object]​ ... This will be used to configure minimum threshold enforcement for coverage results. Thresholds can be specified as ...
Read more >
Configuring code coverage in Jest, the right way
Key takeaway: always configure coverageThreshold in your Jest config to ensure a coverage baseline. Conclusion. If you're using Jest, here are ...
Read more >
Configuring package.json · Jest
Note: Setting this option overwrites the default values. Add "text" or "text-summary" to see a coverage summary in the console output. coverageThreshold [object] ......
Read more >
node.js - Applying jest coverageThreshold to aggregated report
Instead of combining the tasks, combine only the pathPattern. You can try to create a single task for group1 and group2 something like...
Read more >
jest-coverage-thresholds-bumper - npm
Tool supports jest.config.json and jest.config.js configuration files, as well as jest section in package.json .
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found