0
Fork 0
mirror of https://github.com/logto-io/logto.git synced 2024-12-23 20:33:16 -05:00
logto/packages/core/jest.config.ts

21 lines
560 B
TypeScript
Raw Normal View History

2022-11-21 03:38:24 -05:00
import type { Config } from '@silverhand/jest-config';
import { merge } from '@silverhand/jest-config';
const config: Config.InitialOptions = merge({
2022-11-21 03:38:24 -05:00
preset: 'ts-jest/presets/js-with-ts-esm',
testPathIgnorePatterns: ['/core/connectors/'],
setupFilesAfterEnv: ['jest-matcher-specific-error', './jest.setup.ts'],
2022-11-21 03:38:24 -05:00
moduleNameMapper: {
'^#src/(.*)\\.js(x)?$': '<rootDir>/src/$1',
'^(\\.{1,2}/.*)\\.js$': '$1',
},
globals: {
'ts-jest': {
useESM: true,
},
},
extensionsToTreatAsEsm: ['.ts', '.tsx'],
});
export default config;