Skip to content

Commit 4ad857b

Browse files
committed
chore: Try a new apporach for testing legacy Node versions
1 parent 8c1979a commit 4ad857b

File tree

1 file changed

+16
-6
lines changed

1 file changed

+16
-6
lines changed

.github/workflows/ci.yml

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,21 +14,29 @@ jobs:
1414
matrix:
1515
node: ["9", "10"]
1616
runs-on: ubuntu-20.04
17-
container:
18-
image: node:${{ matrix.node }}
17+
timeout-minutes: 30
1918
steps:
2019
- name: Checkout
2120
uses: actions/checkout@v4
2221

22+
- name: Setup Node.js (legacy)
23+
uses: actions/setup-node@v3
24+
with:
25+
node-version: ${{ matrix.node }}
26+
registry-url: 'https://registry.npmjs.org'
27+
2328
- name: Print Node & npm versions
2429
run: |
2530
node -v
2631
npm -v
2732
28-
- name: Install dependencies
29-
run: npm ci || npm i
33+
- name: Install dependencies (legacy compatible)
34+
run: |
35+
npm config set registry https://registry.npmjs.org/
36+
npm install --no-package-lock --legacy-peer-deps || npm install --no-package-lock
3037
31-
- name: Run tests (Travis parity)
38+
- name: Run tests with timeout
39+
timeout-minutes: 25
3240
run: npm run test-with-temp-cloud
3341

3442
test-modern:
@@ -38,6 +46,7 @@ jobs:
3846
matrix:
3947
node: ["12", "14", "16", "18", "20", "22"]
4048
runs-on: ubuntu-latest
49+
timeout-minutes: 30
4150
steps:
4251
- name: Checkout
4352
uses: actions/checkout@v4
@@ -55,5 +64,6 @@ jobs:
5564
- name: Install dependencies
5665
run: npm ci || npm i
5766

58-
- name: Run tests (Travis parity)
67+
- name: Run tests with timeout
68+
timeout-minutes: 25
5969
run: npm run test-with-temp-cloud

0 commit comments

Comments
 (0)