Skip to content

Commit

Permalink
ci: skip exec args tests for node >20.15 (#6375)
Browse files Browse the repository at this point in the history
  • Loading branch information
sheremet-va committed Sep 12, 2024
1 parent 259147d commit f111774
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
10 changes: 4 additions & 6 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,11 @@ jobs:
lint:
timeout-minutes: 10
runs-on: ubuntu-latest
name: 'Lint: node-20.14, ubuntu-latest'
name: 'Lint: node-latest, ubuntu-latest'
steps:
- uses: actions/checkout@v4

- uses: ./.github/actions/setup-and-cache
with:
node-version: 20.14

- name: Install
run: pnpm i
Expand Down Expand Up @@ -84,13 +82,13 @@ jobs:
os: [ubuntu-latest]
# Reset back to 20 after https://github.com/nodejs/node/issues/53648
# (The issues is closed, but the error persist even after 20.14)
node_version: [18, 20.14]
node_version: [18, 20]
# node_version: [18, 20, 22] 22 when LTS is close enough
include:
- os: macos-14
node_version: 20.14
node_version: 20
- os: windows-latest
node_version: 20.14
node_version: 20
fail-fast: false

steps:
Expand Down
5 changes: 4 additions & 1 deletion test/config/test/exec-args.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ import { expect, test } from 'vitest'
import { execa } from 'execa'
import { runVitest } from '../../test-utils'

const [nodeMajor, nodeMinor] = process.version.slice(1).split('.').map(Number)

test.each([
{ pool: 'forks', execArgv: ['--hash-seed=1', '--random-seed=1', '--no-opt'] },
{ pool: 'threads', execArgv: ['--inspect-brk'] },
Expand All @@ -10,7 +12,8 @@ test.each([
const root = './fixtures/exec-args-fixtures'
const fileToTest = `${pool}.test.ts`

if (process.version === 'v20.15.0' && pool !== 'forks') {
// TODO: node.js has a bug that makes --inspect-brk not work on worker threads
if (nodeMajor === 20 && nodeMinor > 14 && pool !== 'forks') {
return
}

Expand Down

0 comments on commit f111774

Please sign in to comment.