forked from promptfoo/promptfoo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
jest.config.ts
22 lines (19 loc) · 708 Bytes
/
jest.config.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
/** @type {import('ts-jest/dist/types').InitialOptionsTsJest} */
import type { Config } from 'jest';
import type { TsJestTransformerOptions } from 'ts-jest';
const tsJestConfig: TsJestTransformerOptions & Record<string, unknown> = { useESM: true };
const config: Config = {
transform: {
'^.+\\.m?[tj]sx?$': ['ts-jest', tsJestConfig],
},
/*
moduleNameMapper: {
'(.+)\\.js': '$1',
},
*/
extensionsToTreatAsEsm: ['.ts'],
setupFiles: ['<rootDir>/.jest/setEnvVars.js'],
testPathIgnorePatterns: ['<rootDir>/examples', '<rootDir>/node_modules', '<rootDir>/dist'],
modulePathIgnorePatterns: ['<rootDir>/examples', '<rootDir>/node_modules', '<rootDir>/dist'],
};
export default config;