diff --git a/test/test.js b/test/test.js index b5f8f9e..35da00f 100644 --- a/test/test.js +++ b/test/test.js @@ -2,6 +2,7 @@ const EC = require('eight-colors'); const { spawn } = require('node:child_process'); const Util = require('../lib/utils/util.js'); +// eslint-disable-next-line complexity const executeNpmRun = (item) => { const nv = process.versions.node; @@ -32,6 +33,16 @@ const executeNpmRun = (item) => { } + if (Util.cmpVersion(nv, '22') > 0) { + + // module register added in Node.js: v20.6.0 + if (item.includes('tsx')) { + EC.logYellow(`Ignore test tsx - node ${nv} > 22`); + return 0; + } + + } + return new Promise((resolve) => { const worker = spawn(`npm run ${item}`, { shell: true,