Skip to content

Commit 3da9d30

Browse files
committed
Add code coverage reports to unit tests
1 parent 89a12b5 commit 3da9d30

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
.nyc_output/
12
.idea
23
.npm
34
.tmp

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
"build:release": "npm install --production && npm install typescript firebase-admin && node_modules/.bin/tsc -p tsconfig.release.json",
1010
"lint": "node_modules/.bin/tslint src/{**/*,*}.ts spec/{**/*,*}.ts integration_test/functions/src/{**/*,*}.ts",
1111
"pretest": "node_modules/.bin/tsc && cp -r spec/fixtures .tmp/spec",
12-
"test": "mocha .tmp/spec/index.spec.js",
12+
"test": "nyc -x .tmp/spec --reporter=text mocha .tmp/spec/index.spec.js",
1313
"posttest": "npm run lint && rm -rf .tmp"
1414
},
1515
"repository": {
@@ -43,6 +43,7 @@
4343
"mocha": "^2.4.5",
4444
"mock-require": "^2.0.1",
4545
"nock": "^8.0.0",
46+
"nyc": "^11.1.0",
4647
"sinon": "^1.17.4",
4748
"tslint": "^3.15.1",
4849
"typescript": "^2.0.3"

0 commit comments

Comments
 (0)