chore: enable cache on CI/CD

This commit is contained in:
Florian Bouillon 2024-08-30 11:05:02 +02:00 committed by GitHub
parent 4364da480f
commit f2621890e1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -14,9 +14,10 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
strategy: strategy:
fail-fast: false
matrix: matrix:
# Follow current releases https://github.com/nodejs/release#release-schedule # Follow current releases https://github.com/nodejs/release#release-schedule
node-version: [18.x, 20.x, 21.x] node-version: [18.x, 20.x, 21.x, 22.x]
steps: steps:
- name: Checkout - name: Checkout
@ -26,6 +27,7 @@ jobs:
uses: actions/setup-node@v3 uses: actions/setup-node@v3
with: with:
node-version: ${{ matrix.node-version }} node-version: ${{ matrix.node-version }}
cache: 'npm'
- name: Install dependencies - name: Install dependencies
run: npm ci run: npm ci
@ -37,7 +39,7 @@ jobs:
run: npm run test run: npm run test
- name: Upload Coverage - name: Upload Coverage
if: matrix.node-version == '21.x' if: matrix.node-version == '22.x'
uses: codecov/codecov-action@v3 uses: codecov/codecov-action@v3
with: with:
# Comma-separated list of files to upload # Comma-separated list of files to upload