-
Notifications
You must be signed in to change notification settings - Fork 33
Expand file tree
/
Copy pathjest.config.js
More file actions
36 lines (35 loc) · 1009 Bytes
/
jest.config.js
File metadata and controls
36 lines (35 loc) · 1009 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
const { jsWithBabel: tsjPreset } = require('ts-jest/presets');
module.exports = {
transform: {
...tsjPreset.transform,
},
testRegex: '(/__tests__/.*|(\\.|/)(tests))\\.(jsx?|tsx?|js?|ts?)$',
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx'],
testPathIgnorePatterns: ['node_modules'],
transformIgnorePatterns: ['node_modules/?!(@fluentui/react)'],
moduleNameMapper: {},
moduleDirectories: ['node_modules', 'src'],
modulePathIgnorePatterns: [],
snapshotSerializers: ['enzyme-to-json/serializer'],
setupFiles: ['<rootDir>/test.config.ts'],
testResultsProcessor: '<rootDir>/test-result.config.js',
coverageReporters: ['cobertura', 'text'],
collectCoverage: true,
collectCoverageFrom: [
'**/*.{ts,tsx}',
'!**/lib/**',
'!**/*.types.ts',
'!**/*.action-types.ts',
'!**/*.styled.ts',
'!**/*.actions.ts',
'!**/index.ts',
],
coverageThreshold: {
global: {
branches: 30,
functions: 30,
lines: 30,
statements: 30,
},
},
};