From 417801ef6d1f4343e2205614f9965ce54d086297 Mon Sep 17 00:00:00 2001 From: Bryan Mishkin <698306+bmish@users.noreply.github.com> Date: Fri, 6 Dec 2024 15:58:31 -0500 Subject: [PATCH] feat!: require Node 18, 20, 22+ --- .github/workflows/ci.yml | 2 +- jest.config.cjs | 9 --------- package.json | 2 +- 3 files changed, 2 insertions(+), 11 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 970260ab..f6c6e24c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -21,7 +21,7 @@ jobs: fail-fast: false matrix: os: [ ubuntu, windows ] - node-version: [18.x] + node-version: [18.x, 20.x, 22.x, 23.x] steps: - uses: actions/checkout@v4 diff --git a/jest.config.cjs b/jest.config.cjs index bb4fd7d6..d7c30a72 100644 --- a/jest.config.cjs +++ b/jest.config.cjs @@ -32,13 +32,4 @@ const jestConfig = { }, }; -if (process.version.startsWith('v14.')) { - // TODO: remove this workaround after dropping support for Node 14. - // Use number greater than number of test suites to avoid: "You are trying to `import` a file after the Jest environment has been torn down." - // https://github.com/facebook/jest/issues/11438#issuecomment-954155180 - jestConfig.maxConcurrency = 30; - jestConfig.maxWorkers = 30; - jestConfig.testTimeout = 10_000; // 10 seconds timeout (twice the default) -} - module.exports = jestConfig; diff --git a/package.json b/package.json index 0423d756..5c1981f7 100644 --- a/package.json +++ b/package.json @@ -88,7 +88,7 @@ "eslint": ">= 7" }, "engines": { - "node": "^14.18.0 || ^16.0.0 || >=18.0.0" + "node": "^18.0.0 || ^20.0.0 || >=22.0.0" }, "publishConfig": { "registry": "https://registry.npmjs.org"