-
-
Notifications
You must be signed in to change notification settings - Fork 29
40 lines (40 loc) · 982 Bytes
/
npm-test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
name: test
on:
push:
pull_request:
branches: [master]
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os:
- ubuntu-latest
- macos-latest
- windows-latest
node_version:
- 16
- 18
- 20
architecture:
- x64
# an extra windows-x86 run:
include:
- os: windows-latest
node_version: 16
architecture: x86
name: Node ${{ matrix.node_version }} - ${{ matrix.architecture }} on ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- name: Setup node
uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node_version }}
architecture: ${{ matrix.architecture }}
cache: "npm"
- name: Install latest npm
run: npm i -g npm@latest
- name: Clean install dependencies
run: npm ci
- name: Run tests
run: npm test