diff --git a/libs/shared/jest.config.js b/libs/shared/jest.config.js index a11a1ac3f20..aa1094da3c3 100644 --- a/libs/shared/jest.config.js +++ b/libs/shared/jest.config.js @@ -1,4 +1,5 @@ /* eslint-env node */ +const path = require("path"); /** @type {import('jest').Config} */ module.exports = { @@ -15,7 +16,7 @@ module.exports = { // Also anecdotally improves performance when run locally maxWorkers: 3, - setupFiles: ["/../../libs/shared/polyfill-node-globals.ts"], + setupFiles: [path.join(__dirname, "polyfill-node-globals.ts")], transform: { "^.+\\.tsx?$": [ diff --git a/libs/tools/export/vault-export/vault-export-core/jest.config.js b/libs/tools/export/vault-export/vault-export-core/jest.config.js index 1cd8df2a0e4..d28c110d2ad 100644 --- a/libs/tools/export/vault-export/vault-export-core/jest.config.js +++ b/libs/tools/export/vault-export/vault-export-core/jest.config.js @@ -8,7 +8,6 @@ module.exports = { ...sharedConfig, preset: "ts-jest", testEnvironment: "jsdom", - setupFiles: ["/../../../../../libs/shared/polyfill-node-globals.ts"], moduleNameMapper: pathsToModuleNameMapper( { "@bitwarden/common/spec": ["libs/common/spec"], ...(compilerOptions?.paths ?? {}) }, {