Skip to content

Commit 69f797e

Browse files
committed
Add test coverage collection script
This makes it clear to how collect basic test coverage when desired.
1 parent 4d5fd3e commit 69f797e

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

package.json

+8-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,8 @@
4949
"lint:types": "tsc --noEmit --jsx react",
5050
"lint:style": "stylelint 'res/css/**/*.scss'",
5151
"test": "jest",
52-
"test:e2e": "./test/end-to-end-tests/run.sh --app-url http://localhost:8080"
52+
"test:e2e": "./test/end-to-end-tests/run.sh --app-url http://localhost:8080",
53+
"coverage": "yarn test --coverage"
5354
},
5455
"dependencies": {
5556
"@babel/runtime": "^7.12.5",
@@ -188,6 +189,12 @@
188189
},
189190
"transformIgnorePatterns": [
190191
"/node_modules/(?!matrix-js-sdk).+$"
192+
],
193+
"collectCoverageFrom": [
194+
"<rootDir>/src/**/*.{js,ts,tsx}"
195+
],
196+
"coverageReporters": [
197+
"text"
191198
]
192199
}
193200
}

0 commit comments

Comments
 (0)