-
-
Notifications
You must be signed in to change notification settings - Fork 1
47 lines (45 loc) · 1.18 KB
/
npt.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
name: Node.js versions
on: push
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: 14
- name: Install dependencies
run: npm ci
- name: Pack tests
run: npx npt pack -c .package-tester.json
- uses: actions/upload-artifact@master
with:
name: package-tests
path: tmp
test:
runs-on: ${{ matrix.os }}
env:
YARGS_MIN_NODE_VERSION: ${{ matrix.node }}
strategy:
matrix:
os: [ macos-latest, windows-latest, ubuntu-latest ]
node: [ 10, 12, 14, 16 ]
needs: build
steps:
- uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node }}
- name: Show configuration
run: |
npm config get user-agent
- uses: actions/checkout@master
- uses: actions/download-artifact@master
with:
name: package-tests
path: tmp
- name: Install dependencies
working-directory: tmp/package-tests
run: npm install
- name: Run tests
working-directory: tmp/package-tests
run: npm run test