Skip to content

Commit

Permalink
ci: publish coverage to codecov (#10)
Browse files Browse the repository at this point in the history
  • Loading branch information
hugocaillard authored Oct 17, 2024
1 parent ce4fe5e commit 14cd7ff
Showing 1 changed file with 16 additions and 9 deletions.
25 changes: 16 additions & 9 deletions .github/workflows/test-contrat.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ on:
branches: [ "main" ]

jobs:
build:
test:

runs-on: ubuntu-latest

Expand All @@ -20,11 +20,18 @@ jobs:
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/

steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- run: npm ci
- run: npm test
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- run: npm ci
- run: npm run test:reports

- name: Upload coverage data to codecov
if: ${{ matrix.node-version == '20.x' }}
uses: codecov/codecov-action@v4
with:
files: lcov.info
token: ${{ secrets.CODECOV_TOKEN }}

0 comments on commit 14cd7ff

Please sign in to comment.