Skip to content

Commit fcc2df6

Browse files
committed
Update coverage settings for jest and karma
1 parent dbba4d1 commit fcc2df6

File tree

4 files changed

+8
-4
lines changed

4 files changed

+8
-4
lines changed

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ npm-debug.log*
44
yarn-error.log
55
/dist
66
/test/*coverage
7-
/test/coverage-jest
7+
/test/coverage*
88
/.chrome
99

1010
# Logs #

package-scripts.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,15 @@ module.exports = {
77
test: {
88
default: 'nps test.jest',
99
jest: {
10-
default: 'jest',
10+
default: series(
11+
rimraf('test/coverage-jest'),
12+
'jest'
13+
),
1114
watch: 'jest --watch',
1215
},
1316
karma: {
1417
default: series(
15-
rimraf('test/karma-coverage'),
18+
rimraf('test/coverage-karma'),
1619
'karma start test/karma.conf.js'
1720
),
1821
watch: 'karma start test/karma.conf.js --no-single-run',

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,7 @@
106106
"istanbul-instrumenter-loader": "^2.0.0",
107107
"jasmine-core": "^2.6.2",
108108
"jest": "^20.0.3",
109+
"jest-cli": "^20.0.3",
109110
"json-loader": "^0.5.4",
110111
"karma": "^1.7.0",
111112
"karma-chrome-launcher": "^2.1.1",

test/karma.conf.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ module.exports = function (config) {
4343

4444
coverageIstanbulReporter: {
4545
reports: [ 'html', 'lcovonly', 'text-summary' ],
46-
dir: path.resolve(__dirname, 'karma-coverage'),
46+
dir: path.resolve(__dirname, 'coverage-karma'),
4747
fixWebpackSourcePaths: true,
4848
},
4949

0 commit comments

Comments
 (0)