Skip to content

Use node16 for v2; the node20 will be used by v3 #800

Use node16 for v2; the node20 will be used by v3

Use node16 for v2; the node20 will be used by v3 #800

Workflow file for this run

---
name: Unit tests
on:
push:
branches: [ main, node16 ]
pull_request:
branches: [ main, node16 ]
workflow_dispatch:
permissions:
contents: read
jobs:
test:
name: Unit Tests - Node.js
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [ 18.x, 20.x ]
steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: yarn
cache-dependency-path: yarn.lock
- name: Install
run: yarn install
- name: Compile
run: yarn build
- name: Package
run: yarn run package
- name: Test
run: yarn test
- name: Codecov
if: ${{ matrix.node-version == '20.x' }}
uses: codecov/codecov-action@v3