Files

27 lines
695 B
JavaScript
Raw Permalink Normal View History

2022-06-02 15:53:11 -04:00
module.exports = {
clearMocks: true,
2025-07-29 11:06:45 +02:00
preset: 'ts-jest',
2022-06-02 15:53:11 -04:00
moduleFileExtensions: ['js', 'ts'],
testEnvironment: 'node',
testMatch: ['**/*-test.ts'],
testRunner: 'jest-circus/runner',
2025-07-29 11:06:45 +02:00
verbose: true,
2022-06-02 15:53:11 -04:00
transform: {
2025-07-29 11:06:45 +02:00
'^.+\\.ts$': [
'ts-jest',
{
tsconfig: 'tsconfig.test.json'
}
],
// Transform ESM modules to CommonJS
'^.+\\.(js|mjs)$': ['babel-jest', {
presets: [['@babel/preset-env', { targets: { node: 'current' } }]]
}]
2022-06-02 15:53:11 -04:00
},
2025-07-29 11:06:45 +02:00
transformIgnorePatterns: [
// Transform these ESM packages
'node_modules/(?!(shlex|@kubernetes/client-node|openid-client|oauth4webapi|jose|uuid)/)'
],
setupFilesAfterEnv: ['./jest.setup.js']
2022-06-02 15:53:11 -04:00
}