Unverified Commit be618048 authored by Steven's avatar Steven Committed by GitHub

chore(test): run unit tests on node 18 and 20 (#57199)

Since we separated unit tests into its own job in PR https://github.com/vercel/next.js/pull/55621, we can now run unit tests against Node.js 18 and Node.js 20 (maintenance and lts) using a matrix.
parent 1c5d7782
...@@ -9,6 +9,7 @@ on: ...@@ -9,6 +9,7 @@ on:
env: env:
NAPI_CLI_VERSION: 2.14.7 NAPI_CLI_VERSION: 2.14.7
TURBO_VERSION: 1.10.9 TURBO_VERSION: 1.10.9
NODE_MAINTENANCE_VERSION: 18
NODE_LTS_VERSION: 20 NODE_LTS_VERSION: 20
TEST_CONCURRENCY: 8 TEST_CONCURRENCY: 8
# disable backtrace for test snapshots # disable backtrace for test snapshots
...@@ -164,9 +165,12 @@ jobs: ...@@ -164,9 +165,12 @@ jobs:
name: test unit name: test unit
strategy: strategy:
fail-fast: false fail-fast: false
matrix:
node: [18, 20] # TODO: use env var like [env.NODE_MAINTENANCE_VERSION, env.NODE_LTS_VERSION]
uses: ./.github/workflows/build_reusable.yml uses: ./.github/workflows/build_reusable.yml
with: with:
nodeVersion: ${{ matrix.node }}
skipForDocsOnly: 'yes' skipForDocsOnly: 'yes'
afterBuild: node run-tests.js -c ${TEST_CONCURRENCY} --type unit afterBuild: node run-tests.js -c ${TEST_CONCURRENCY} --type unit
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment