1 | name: CI
|
2 |
|
3 | on:
|
4 | push:
|
5 | branches: [ master, 'v*' ]
|
6 | pull_request:
|
7 | branches: [ master, 'v*' ]
|
8 |
|
9 | jobs:
|
10 | test:
|
11 |
|
12 | runs-on: ubuntu-latest
|
13 |
|
14 | strategy:
|
15 | fail-fast: false
|
16 | matrix:
|
17 | node-version: [10.x, 12.x, 14.x, 16.x, 18.x, 20.x]
|
18 |
|
19 | steps:
|
20 | - uses: actions/checkout@v4
|
21 | - uses: actions/setup-node@v4
|
22 | with:
|
23 | node-version: ${{ matrix.node-version }}
|
24 | cache: npm
|
25 | - run: npm i -g npm@7
|
26 | if: ${{ matrix.node-version == '10.x' || matrix.node-version == '12.x' || matrix.node-version == '14.x' }}
|
27 | - run: npm ci
|
28 | - run: npm run lint:js
|
29 | - run: npm test
|