From 3d6687419d180f6fd7ff68cf143d42f55efab912 Mon Sep 17 00:00:00 2001 From: Michael Keaton Date: Tue, 19 Nov 2024 16:47:56 +0100 Subject: [PATCH] ci: update and improve ci workflow (#72) * ci: update actions and node version * ci: use 'npm ci' instead of 'npm install' * ci: run linter * ci: run build --- .github/workflows/ci.yml | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 93f8602..3ffe3e1 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -8,22 +8,31 @@ on: jobs: test: runs-on: ubuntu-latest + strategy: + matrix: + node-version: ['v22.11.0'] steps: - name: Checkout code - uses: actions/checkout@v3 + uses: actions/checkout@v4 - - name: Set up Node.js - uses: actions/setup-node@v3 + - name: Set up Node.js (${{ matrix.node-version }}) + uses: actions/setup-node@v4 with: - node-version: '18' + node-version: ${{ matrix.node-version }} - name: Install dependencies - run: npm install + run: npm ci + + - name: Lint + run: npm run lint - name: Run tests and generate coverage run: npm run test -- --coverage + - name: Build + run: npm run build + - name: Upload coverage to Codecov uses: codecov/codecov-action@v4 with: