ci: smoke test node 12 and 16 separately

This commit is contained in:
Amin Yahyaabadi 2023-04-24 13:49:29 -07:00
parent 39419e1292
commit 4aa1b0647c
1 changed files with 18 additions and 8 deletions

View File

@ -23,11 +23,7 @@ jobs:
- ubuntu-20.04 - ubuntu-20.04
- macos-12 - macos-12
- macos-11 - macos-11
cache_reset_counter:
- 0
node: node:
- 12
- 16
- 18 - 18
pnpm: pnpm:
- 8 - 8
@ -64,10 +60,26 @@ jobs:
# uses: mxschmitt/action-tmate@v3 # uses: mxschmitt/action-tmate@v3
- name: Test - name: Test
if: "${{ !contains(github.event.head_commit.message, '[skip test]') && contains(matrix.node, '18') }}" if: "${{ !contains(github.event.head_commit.message, '[skip test]') }}"
run: | run: |
pnpm run test pnpm run test
- name: Setup Node 12
uses: actions/setup-node@v3
with:
node-version: 12
- name: Smoke Test Node 12
run: |
node ./dist/node12/setup-cpp.js --help
- name: Setup Node 16
uses: actions/setup-node@v3
with:
node-version: 16
- name: Smoke Test Node 16
run: |
node ./dist/node16/setup-cpp.js --help
# Create self-contained executable that bundles Nodejs # Create self-contained executable that bundles Nodejs
- name: Create Executable - name: Create Executable
if: "${{ contains(matrix.os, 'windows-2022') || contains(matrix.os, 'ubuntu-22.04') || contains(matrix.os, 'macos-12') }}" if: "${{ contains(matrix.os, 'windows-2022') || contains(matrix.os, 'ubuntu-22.04') || contains(matrix.os, 'macos-12') }}"
@ -127,8 +139,6 @@ jobs:
- "ubuntu_20.04_node.dockerfile" - "ubuntu_20.04_node.dockerfile"
- "ubuntu_node_legacy.dockerfile" - "ubuntu_node_legacy.dockerfile"
- "ubuntu_node.dockerfile" - "ubuntu_node.dockerfile"
cache_reset_counter:
- 0
steps: steps:
- uses: actions/checkout@v3 - uses: actions/checkout@v3
with: with:
@ -140,7 +150,7 @@ jobs:
path: | path: |
~/.pnpm-store ~/.pnpm-store
D:\.pnpm-store D:\.pnpm-store
key: "setupcpp-docker-cache-OS:${{ matrix.os }}-node:${{ matrix.node }}-pnpm:${{ matrix.pnpm }}-${{ hashFiles('./.npmrc') }}-deps:${{ hashFiles('./package.json') }}-${{ matrix.cache_reset_counter }}" key: "setupcpp-docker-cache-OS:${{ matrix.os }}-${{ hashFiles('./.npmrc') }}-deps:${{ hashFiles('./package.json') }}"
restore-keys: | restore-keys: |
"setupcpp-docker-cache-OS:${{ matrix.os }}" "setupcpp-docker-cache-OS:${{ matrix.os }}"