Skip to content

Commit

Permalink
ci: add conditional test coverage for different Node.js versions
Browse files Browse the repository at this point in the history
  • Loading branch information
microshine committed Mar 29, 2024
1 parent cef28b7 commit d69d887
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,14 @@ jobs:
- name: Run linter
run: npm run lint

- name: Run test with coverage
- name: Run test with coverage for Node.js < 20
if: ${{ matrix.node-version < 20 }}
run: npm run coverage

- name: Run test with coverage for Node.js >= 20
if: ${{ matrix.node-version >= 20 }}
run: node --security-revert=CVE-2023-46809 ./node_modules/.bin/nyc npm run test

- name: Coveralls
uses: coverallsapp/github-action@master
with:
Expand Down

0 comments on commit d69d887

Please sign in to comment.