Skip to content

Commit 6642604

Browse files
committed
add a github actions workflow
1 parent 2ab63e5 commit 6642604

File tree

1 file changed

+46
-0
lines changed

1 file changed

+46
-0
lines changed

.github/workflows/test.yml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: Build package and run tests
2+
3+
# newer commits in the same PR abort running ones for the same workflow
4+
concurrency:
5+
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
6+
cancel-in-progress: true
7+
8+
on:
9+
push:
10+
branches:
11+
- main
12+
pull_request:
13+
branches:
14+
- main
15+
workflow_dispatch:
16+
inputs:
17+
debug_enabled:
18+
type: boolean
19+
description: "Run the build with tmate debugging enabled (https://github.com/marketplace/actions/debugging-with-tmate)"
20+
required: false
21+
default: false
22+
23+
jobs:
24+
build:
25+
runs-on: ubuntu-latest
26+
27+
strategy:
28+
matrix:
29+
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
30+
node-version:
31+
- "18"
32+
- "20"
33+
- "22"
34+
- "24"
35+
36+
steps:
37+
- uses: actions/checkout@v4
38+
39+
- name: Node.js ${{ matrix.node-version }}
40+
uses: actions/setup-node@v4
41+
with:
42+
node-version: ${{ matrix.node-version }}
43+
- run: npm install -g pnpm
44+
- run: pnpm install
45+
- run: pnpm build
46+
- run: pnpm test

0 commit comments

Comments
 (0)