Skip to content

check

check #146

Workflow file for this run

name: check
on:
push:
branches:
- master
tags:
- v*
pull_request:
branches:
- master
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
check:
name: Build & Lint & Test
runs-on: ubuntu-latest
strategy:
fail-fast: true
matrix:
node-version: [16.x, 18.x, 20.x]
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- name: Install Dependencies
run: |
npm ci
- name: Build
run: |
npm run build
npm run build:benchmarks
- name: Check
# only run on newest node version
if: matrix.node-version == '20.x'
run: |
npm run check
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Test
run: npm run test:ci
env:
CI: true
- name: Upload code coverage
uses: codecov/codecov-action@v3
if: matrix.node-version == '18.x'