Skip to content

Commit

Permalink
Skip CI tests for Node.js < 20
Browse files Browse the repository at this point in the history
  • Loading branch information
eemeli committed Feb 24, 2024
1 parent c571406 commit b7a0851
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
1 change: 1 addition & 0 deletions config/jest.config.js
Expand Up @@ -12,6 +12,7 @@ switch (process.env.npm_lifecycle_event) {
console.log('Testing build output from dist/')
moduleNameMapper = {
'^yaml$': '<rootDir>/dist/index.js',
'^yaml/cli$': '<rootDir>/dist/cli.js',
'^yaml/util$': '<rootDir>/dist/util.js',
'^../src/test-events$': '<rootDir>/dist/test-events.js'
}
Expand Down
5 changes: 4 additions & 1 deletion tests/cli.ts
@@ -1,7 +1,10 @@
import { Readable } from 'node:stream'
import { main } from 'yaml/cli'

describe('CLI', () => {
const [major] = process.versions.node.split('.')
const skip = Number(major) < 20

;(skip ? describe.skip : describe)('CLI', () => {
const stdout: unknown[] = []
const stderr: unknown[] = []
beforeAll(() => {
Expand Down

0 comments on commit b7a0851

Please sign in to comment.