Testing · Middle · Question 38 of 75
What does a coverage threshold in config do?
coverage: { thresholds: { lines: 80, branches: 70 } }- ✓Correct answer: Fails the test run if coverage drops below the numbers
- 2Runs only 80% of the tests
- 3Hides files below 80% from the report
Explanation
Thresholds prevent coverage from silently going down; they shouldn't become a goal by themselves.