Skip to content

Commit

Permalink
fix: refactored Jest test execution on CI (#93)
Browse files Browse the repository at this point in the history
* fix: jest run all tests in the same run
Closes #46

* feat: cleanup

* fix: t

* fix: coverage
  • Loading branch information
mxschmitt committed Mar 31, 2020
1 parent 1165521 commit 4edc0f4
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 2 deletions.
File renamed without changes.
File renamed without changes.
6 changes: 6 additions & 0 deletions jest.config.e2e.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
module.exports = {
preset: 'ts-jest',
testEnvironment: './lib/PlaywrightEnvironment.js',
testPathIgnorePatterns: ['/node_modules/', 'lib'],
testMatch: ['**/e2e/**/*.test.ts'],
}
2 changes: 1 addition & 1 deletion jest.config.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module.exports = {
preset: 'ts-jest',
testEnvironment: './lib/PlaywrightEnvironment.js',
testPathIgnorePatterns: ['/node_modules/', 'lib'],
testMatch: ['**/src/**/*.test.ts'],
collectCoverage: true,
}
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,9 @@
"format": "prettier --write \"*.{js,md}\" \"src/**/*.js\"",
"lint": "tsc --noEmit && eslint . --ext .js,.ts",
"prepublishOnly": "npm run build",
"test": "jest src/bin/utils.test.ts tests/stub.test.ts && jest src/utils.test.ts",
"test": "npm run test:src && npm run test:e2e",
"test:src": "jest",
"test:e2e": "jest -c jest.config.e2e.js",
"coveralls": "jest --coverage && cat ./coverage/lcov.info | coveralls"
},
"husky": {
Expand Down

0 comments on commit 4edc0f4

Please sign in to comment.