18 lines
462 B
TypeScript
18 lines
462 B
TypeScript
import type { Config } from 'jest';
|
|
import { defaults } from 'jest-config';
|
|
|
|
const config: Config = {
|
|
clearMocks: true,
|
|
collectCoverage: true,
|
|
coverageDirectory: "coverage",
|
|
coverageProvider: "v8",
|
|
setupFilesAfterEnv: ['<rootDir>/jest.setup.ts'],
|
|
testEnvironment: "jsdom",
|
|
transform: {
|
|
'^.+\\.(ts|tsx|js|jsx)$': 'babel-jest',
|
|
},
|
|
moduleFileExtensions: [...defaults.moduleFileExtensions, 'ts', 'tsx', 'js', 'jsx'],
|
|
};
|
|
|
|
export default config;
|