Skip to content

Commit

Permalink
Speed up CI unit-test workflow by 28% (#1804)
Browse files Browse the repository at this point in the history
## Which problem is this PR solving?
- I recently benchmarked against some `jest` settings to speed up the
total test execution time.
- The best setting according to GitHub Actions so far, according to
internet and manual testing is using `--maxWorkers=4`

## How was this change tested?
- Executed in 5m 25 s with this setting:
https://github.com/anshgoyalevil/jaeger-ui/actions/runs/6224545765/job/16892986157
- Executed in 8m without this setting:
https://github.com/jaegertracing/jaeger-ui/actions/runs/6222381378/job/16886209310

## Checklist
- [x] I have read
https://github.com/jaegertracing/jaeger/blob/master/CONTRIBUTING_GUIDELINES.md
- [x] I have signed all commits
- [x] I have added unit tests for the new functionality
- [x] I have run lint and test steps successfully
  - for `jaeger`: `make lint test`
  - for `jaeger-ui`: `yarn lint` and `yarn test`

---------

Signed-off-by: Ansh Goyal <[email protected]>
  • Loading branch information
anshgoyalevil authored Sep 18, 2023
1 parent 0ba8779 commit 3ff2041
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/jaeger-ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@
"start:ga-debug": "REACT_APP_GA_DEBUG=1 REACT_APP_VSN_STATE=$(../../scripts/get-tracking-version.js) vite",
"start": "vite",
"test": "jest",
"test-ci": "CI=1 jest --silent --color"
"test-ci": "CI=1 jest --silent --color --maxWorkers=4"
},
"jest": {
"globalSetup": "./test/jest.global-setup.js",
Expand Down

0 comments on commit 3ff2041

Please sign in to comment.