Skip to content

Commit ab6e160

Browse files
committed
ci: Re-introduce tests for Node.js 14.6 and later
1 parent 36dfd51 commit ab6e160

1 file changed

Lines changed: 59 additions & 4 deletions

File tree

.github/workflows/nodejs.yml

Lines changed: 59 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,17 +10,14 @@ on:
1010
jobs:
1111
test:
1212
runs-on: ${{ matrix.os }}
13-
1413
strategy:
1514
matrix:
1615
os: [ubuntu-latest, windows-latest, macos-latest]
1716
node-version: [18, 20, latest]
18-
1917
steps:
2018
- uses: actions/checkout@v4
2119
with: { submodules: true }
22-
- name: Use Node.js ${{ matrix.node-version }}
23-
uses: actions/setup-node@v4
20+
- uses: actions/setup-node@v4
2421
with:
2522
node-version: ${{ matrix.node-version }}
2623
- run: npm ci
@@ -37,3 +34,61 @@ jobs:
3734
with: { node-version: 20 }
3835
- run: npm ci
3936
- run: npm run lint
37+
38+
node-16:
39+
runs-on: ubuntu-latest
40+
strategy:
41+
matrix:
42+
node-version: ['16.0.0', '16']
43+
steps:
44+
- uses: actions/checkout@v4
45+
with: { submodules: true }
46+
- uses: actions/setup-node@v4
47+
with:
48+
node-version: ${{ matrix.node-version }}
49+
- run: npm ci
50+
- run: npm install --no-save rollup@3
51+
- run: npm test
52+
- run: npm run test:dist
53+
54+
node-14-build:
55+
runs-on: ubuntu-latest
56+
strategy:
57+
matrix:
58+
node-version: ['14.18.0']
59+
steps:
60+
- uses: actions/checkout@v4
61+
with: { submodules: true }
62+
- uses: actions/setup-node@v4
63+
with:
64+
node-version: ${{ matrix.node-version }}
65+
- run: npm install --global npm@7
66+
- run: npm ci
67+
- run: npm install --no-save rollup@2
68+
- run: npm run test:dist
69+
- uses: actions/upload-artifact@v4
70+
with:
71+
name: yaml-node14
72+
path: dist/
73+
node-14-run:
74+
needs: node-14-build
75+
runs-on: ubuntu-latest
76+
strategy:
77+
matrix:
78+
node-version: ['14.6.0', '14']
79+
steps:
80+
- uses: actions/checkout@v4
81+
with: { submodules: true }
82+
- uses: actions/setup-node@v4
83+
with:
84+
node-version: ${{ matrix.node-version }}
85+
- run: npm install --global npm@7
86+
- run: npm ci
87+
- run: npm install --no-save jest@27
88+
- uses: actions/download-artifact@v4
89+
with:
90+
name: yaml-node14
91+
path: dist/
92+
- run: npx jest --config config/jest.config.js
93+
env:
94+
npm_lifecycle_event: test:dist

0 commit comments

Comments
 (0)