-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathjest.config.js
More file actions
19 lines (19 loc) · 786 Bytes
/
jest.config.js
File metadata and controls
19 lines (19 loc) · 786 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
module.exports = {
preset: 'ts-jest',
roots: ['<rootDir>/src'],
testRegex: '(/__tests__/.*|(\\.|/)(test|spec))\\.tsx?$',
transform: {
'^.+\\.(ts|tsx)$': 'ts-jest',
'^.+\\.(css|scss|svg)$': '<rootDir>/test-utils/styleTransformer.ts'
},
moduleDirectories: ['node_modules', 'test'],
moduleNameMapper: {
'^.+\\-(style)$': '<rootDir>/test-utils/styleTransformer.ts',
'^.+\\.(css|scss|svg)$': '<rootDir>/test-utils/styleTransformer.ts',
'^react$': '<rootDir>/node_modules/react',
'^react-dom$': '<rootDir>/node_modules/react-dom',
'^react-router$': '<rootDir>/node_modules/react-router'
},
testResultsProcessor: 'jest-sonar-reporter',
setupFilesAfterEnv: ['<rootDir>/test-utils/testSetup.ts']
};