You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

25 lines
738 B

/** @type {import('ts-jest').JestConfigWithTsJest} */
module.exports = {
preset: "ts-jest/presets/default-esm",
globalSetup: "./jest.global-setup.js",
globalTeardown: "./jest.global-teardown.js",
testEnvironment: "node",
testTimeout: 120000,
extensionsToTreatAsEsm: [".ts"],
testPathIgnorePatterns: ["/node_modules/", "/dist/", "/target/"],
moduleNameMapper: {
"^(\\.{1,2}/.*)\\.js$": "$1",
"#ansi-styles": "ansi-styles/index.js",
"#supports-color": "supports-color/index.js",
},
transform: {
// '^.+\\.[tj]sx?$' to process js/ts with `ts-jest`
// '^.+\\.m?[tj]sx?$' to process js/ts/mjs/mts with `ts-jest`
"^.+\\.tsx?$": [
"ts-jest",
{
useESM: true,
},
],
},
}