Skip to content

Commit

Permalink
ci(coverage): Update event target and result name
Browse files Browse the repository at this point in the history
* Targetted 'pull_request' event with type of opened, synchronize, reopened, and ready_for_review
* Updated the file result name by concatenating operating system name
* Added OS name as another flag
  • Loading branch information
mitsuki31 committed Aug 23, 2024
1 parent 96d8ab8 commit c91b1e4
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ name: Codecov Coverage
on:
push:
branches: [ "master" ]
pull_request:
types: [opened, reopened, synchronize, ready_for_review]

jobs:
coverage:
Expand All @@ -25,15 +27,15 @@ jobs:
- name: Clean install the project
run: npm ci
- name: Run coverage
# Currently we only run coverage for unit tests
run: npx nyc --reporter lcov --reporter text npm run test:unit
# Currently only run coverage for unit tests
run: npx nyc npm run test:unit
- name: Upload coverage
uses: codecov/codecov-action@v4
with:
name: codecov-unittest
name: codecov-unittest@${{ matrix.os }}
fail_ci_if_error: true
env_vars: os,node-version
directory: './coverage'
flags: unittests
flags: unittests,${{ matrix.os }}
token: ${{ secrets.CODECOV_TOKEN }}
verbose: true

0 comments on commit c91b1e4

Please sign in to comment.