Skip to content

Commit b8f3a2f

Browse files
committed
action: test on windows with a build matrix
1 parent 82a1cb0 commit b8f3a2f

File tree

1 file changed

+16
-10
lines changed

1 file changed

+16
-10
lines changed

.github/workflows/test.yml

Lines changed: 16 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,27 @@
11
name: Node CI
22

3-
on: [push]
3+
on: [push, pull_request]
44

55
jobs:
66
build:
7-
8-
runs-on: ubuntu-latest
9-
107
strategy:
118
matrix:
12-
node-version: [8.x, 10.x, 12.x]
13-
9+
node: [8.x, 10.x, 12.x]
10+
os: [ubuntu-latest, windows-latest]
11+
cmd: [npm cit]
12+
exclude: # only test windows on node 12
13+
- os: windows-latest
14+
node: 8.x
15+
- os: windows-latest
16+
node: 10.x
17+
- os: windows-latest
18+
node: 12.x
19+
runs-on: ${{ matrix.os }}
1420
steps:
1521
- uses: actions/checkout@v1
16-
- name: Use Node.js ${{ matrix.node-version }}
22+
- name: Use Node.js ${{ matrix.node }}
1723
uses: actions/setup-node@v1
1824
with:
19-
node-version: ${{ matrix.node-version }}
20-
- name: npm install and test
21-
run: npm cit
25+
node-version: ${{ matrix.node }}
26+
- name: ${{ matrix.cmd }}
27+
run: ${{ matrix.cmd }}

0 commit comments

Comments
 (0)