-
Notifications
You must be signed in to change notification settings - Fork 11.9k
Closed
Labels
P5The team acknowledges the request but does not plan to address it, it remains open for discussionThe team acknowledges the request but does not plan to address it, it remains open for discussioneffort1: easy (hours)
Description
- [ ] bug report -> please search issues before submitting
- [x ] feature request
Angular CLI 1.0.1 generates package.json that include an old version of the coverage plugin:
"karma-coverage-istanbul-reporter": "^0.2.0"
As a result, trying to set the thresholds for coverage doesn't work. Upgrade this dependency to
"karma-coverage-istanbul-reporter": "^1.2.0"
This will allow to make the tests with low coverage fail by adding thresholds to karma.conf.js, for example:
coverageIstanbulReporter: {
reports: ['html', 'lcovonly'],
fixWebpackSourcePaths: true,
thresholds: {
global: { // thresholds for all files
statements: 80,
lines: 80,
branches: 80,
functions: 80
},
each: { // thresholds per file
statements: 80,
lines: 80,
branches: 80,
functions: 80
}
}
}
pumano and daBishMan
Metadata
Metadata
Assignees
Labels
P5The team acknowledges the request but does not plan to address it, it remains open for discussionThe team acknowledges the request but does not plan to address it, it remains open for discussioneffort1: easy (hours)