Skip to content

Commit 51049b2

Browse files
move node version tests back to node-compatibility and add os matrix to node tests
1 parent a7ff050 commit 51049b2

File tree

3 files changed

+73
-460
lines changed

3 files changed

+73
-460
lines changed
Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: Node.js Compatibility
2+
3+
on:
4+
push:
5+
branches: [ main ]
6+
pull_request:
7+
workflow_dispatch:
8+
9+
jobs:
10+
node:
11+
runs-on: ${{ matrix.os }}
12+
13+
strategy:
14+
fail-fast: false
15+
matrix:
16+
os: [macos-14, macos-15, macos-15-intel, macos-26, ubuntu-22.04, ubuntu-24.04, windows-2022, windows-2025, ubuntu-22.04-arm, ubuntu-24.04-arm, windows-11-arm]
17+
node-version: [18.x, 19.x, 20.x, 21.x, 22.x, 23.x, 24.x, 25.x]
18+
19+
steps:
20+
- name: Checkout
21+
uses: actions/checkout@v4
22+
23+
- name: Setup node ${{ matrix.node-version }}
24+
uses: actions/setup-node@v4
25+
with:
26+
node-version: ${{ matrix.node-version }}
27+
check-latest: true
28+
29+
- name: Install packages
30+
run: npm ci
31+
32+
- name: Run tests
33+
run: npm run test:ci
34+
35+
- name: Move MySQLMSN directory for GitHub Actions upload
36+
if: ${{ failure() }}
37+
env:
38+
MOVE_MYSQLMSN_TO: ${{ runner.os == 'Windows' && 'C:\\Users\\RUNNER~1\\mysqlmsn' || '/tmp/mysqlmsn' }}
39+
run: npx ts-node tests/ci/DirMoveGitHubActions.ts
40+
41+
- name: Upload mysqlmsn directory
42+
if: ${{ failure() }}
43+
uses: actions/[email protected]
44+
with:
45+
name: node-${{ matrix.node-version }}
46+
path: ${{ runner.os == 'Windows' && 'C:\\Users\\RUNNER~1\\mysqlmsn' || '/tmp/mysqlmsn' }}
47+
compression-level: 0

.github/workflows/old-node-tests.yml

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,13 @@ on:
88

99
jobs:
1010
node:
11-
runs-on: ubuntu-latest
11+
runs-on: ${{ matrix.os }}
1212

1313
strategy:
1414
fail-fast: false
1515
matrix:
1616
node-version: [16.6.0, 16.x, 17.0.0, 17.x]
17+
os: [macos-14, macos-15, macos-15-intel, macos-26, ubuntu-22.04, ubuntu-24.04, windows-2022, windows-2025, ubuntu-22.04-arm, ubuntu-24.04-arm, windows-11-arm]
1718

1819
steps:
1920
- name: Checkout
@@ -31,10 +32,16 @@ jobs:
3132
- name: Run tests
3233
run: npx ts-node tests/old-node.ts
3334

35+
- name: Move MySQLMSN directory for GitHub Actions upload
36+
if: ${{ failure() }}
37+
env:
38+
MOVE_MYSQLMSN_TO: ${{ runner.os == 'Windows' && 'C:\\Users\\RUNNER~1\\mysqlmsn' || '/tmp/mysqlmsn' }}
39+
run: npx ts-node tests/ci/DirMoveGitHubActions.ts
40+
3441
- name: Upload mysqlmsn directory
3542
if: ${{ failure() }}
3643
uses: actions/[email protected]
3744
with:
3845
name: node-${{ matrix.node-version }}
39-
path: /tmp/mysqlmsn
40-
compression-level: 9
46+
path: ${{ runner.os == 'Windows' && 'C:\\Users\\RUNNER~1\\mysqlmsn' || '/tmp/mysqlmsn' }}
47+
compression-level: 0

0 commit comments

Comments
 (0)