DEV;Add Jest coverage setting for CI
This commit is contained in:
parent
a0f41a4e2c
commit
67961b47a3
3 changed files with 6 additions and 3 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -5,6 +5,7 @@
|
|||
# project
|
||||
node_modules/
|
||||
dist/
|
||||
temp/
|
||||
|
||||
lerna-debug.log
|
||||
tsconfig.tsbuildinfo
|
||||
|
|
|
@ -4,7 +4,6 @@ module.exports = {
|
|||
},
|
||||
testRegex: '(/__tests__/.*|(-|/)(test))\\.tsx?$',
|
||||
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'json'],
|
||||
modulePathIgnorePatterns: ['<rootDir>/.vscode/'],
|
||||
moduleNameMapper: {
|
||||
'^documentation(.*)$': '<rootDir>/packages/documentation/src/$1',
|
||||
'^@romanjaros/treejs-components(.*)$': '<rootDir>/packages/treejs-components/src/$1',
|
||||
|
@ -18,6 +17,9 @@ module.exports = {
|
|||
'^@romanjaros/treejs-types(.*)$': '<rootDir>/packages/treejs-types/src/$1',
|
||||
'\\.(css|less|sass|scss)$': '<rootDir>/tests/emptyMock.ts',
|
||||
},
|
||||
collectCoverage: !!process.env.CI,
|
||||
coverageReporters: ['lcov'],
|
||||
coverageDirectory: '<rootDir>/temp/jest',
|
||||
|
||||
// enzyme
|
||||
snapshotSerializers: ['enzyme-to-json/serializer'],
|
||||
|
|
|
@ -18,8 +18,8 @@
|
|||
"build:module": "lerna run --ignore documentation build",
|
||||
"clean:module": "lerna run --ignore documentation clean",
|
||||
"serve": "http-server dist/client",
|
||||
"ci:lint": "npm run lint",
|
||||
"ci:test": "npm run test",
|
||||
"ci:lint": "cross-env CI=true npm run lint",
|
||||
"ci:test": "cross-env CI=true npm run test",
|
||||
"ci:test-e2e": "nightwatch",
|
||||
"ci:build": "lerna run --stream --scope documentation build",
|
||||
"ci:increase-version": "lerna version --no-git-tag-version --no-push --yes"
|
||||
|
|
Loading…
Add table
Reference in a new issue