-
Notifications
You must be signed in to change notification settings - Fork 85
57 lines (48 loc) · 1.1 KB
/
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
name: Test
on:
push:
branches:
- main
pull_request:
branches:
- main
env:
CI: true
jobs:
run:
name: Node ${{ matrix.node }} / ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
- macos-latest
- windows-latest
node:
- 6
- 8
- 10
- 12
- 14
exclude:
# Excludes nodejs v12 and v14 on windows
# https://github.com/nodejs/node/issues/34514
# It was patched in nodejs v15+.
- os: windows-latest
node: 12
- os: windows-latest
node: 14
steps:
- name: Clone repository
uses: actions/checkout@v2
- name: Set Node.js version
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node }}
- run: node --version
- run: npm --version
- name: Install npm dependencies
run: npm install # switch to `ci` when Node.js 6.x is dropped
- name: Run tests
run: npm test