Skip to content

Commit

Permalink
Coverage adjustments for CI leveraging jest workers
Browse files Browse the repository at this point in the history
  • Loading branch information
hwillson committed Aug 16, 2018
1 parent 652dcc2 commit 276f9be
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
10 changes: 9 additions & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,15 @@ jobs:
# needed because npm ci actually removes node_modules before
# installing to guarantee a clean slate.
- ~/.npm
- run: npm run test-ci
- run:
name: Jest suite with coverage
command: npm run test-ci && npm run coverage:upload
environment:
JEST_JUNIT_OUTPUT: "../../reports/junit/js-test-results.xml"
- store_test_results:
path: reports/junit
- store_artifacts:
path: reports/junit

workflows:
version: 2
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -52,3 +52,5 @@ docs.json
docs/public/*
!docs/public/_redirects
.idea/

junit.xml
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@
"diff": "check-if-folder-contents-changed-in-git-commit-range",
"build": "lerna run build",
"test": "jest --verbose",
"test-ci": "npm run test -- --ci --maxWorkers=2",
"test-ci": "npm run coverage -- --ci --maxWorkers=2 --reporters=jest-junit",
"benchmark": "cd packages/apollo-client && npm run benchmark",
"prelint": "npm run lint-fix",
"lint": "lerna run lint",
"lint-fix": "prettier --ignore-path \"./config/prettierignore\" --trailing-comma all --single-quote --write \"packages/*/{src,tests,test,benchmark}/**/*.{j,t}s*\"",
"lint-staged": "lint-staged",
"filesize": "lerna run filesize && bundlesize",
"coverage": "lerna run coverage",
"coverage": "jest --verbose --coverage",
"coverage:upload": "codecov",
"danger": "danger run --verbose --dangerfile=./config/dangerfile.ts",
"deploy": "lerna publish -m \"chore: Publish\" --independent && cd packages/apollo-client && npm run deploy",
Expand Down

0 comments on commit 276f9be

Please sign in to comment.