-
Notifications
You must be signed in to change notification settings - Fork 0
/
jest.config.js
50 lines (50 loc) · 1.39 KB
/
jest.config.js
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
module.exports = {
clearMocks: true,
collectCoverageFrom: [
'src/**/*.{ts,tsx}'
],
coveragePathIgnorePatterns: [
'.*\\.d\\.ts'
],
testMatch: [
'<rootDir>/src/**/*.spec.(ts|tsx)'
],
// This configuration is used to defeat the problem: jest-haste-map: @providesModule naming collision
// Duplicate module name: core-ui-kit
// Paths: C:\dev\projects\ams\core-ui-kit\dist\package.json collides with
// C:\dev\projects\ams\core-ui-kit\package.json
// This warning is caused by a @providesModule declaration with the same name across two different files.
modulePathIgnorePatterns: [
'<rootDir>/dist/'
],
setupFiles: [
'<rootDir>/config/jest/setup/jest-patchers.js'
],
testURL: 'http://localhost',
transform: {
'^(?!.*\\.(js|ts|tsx|css|json)$)': '<rootDir>/config/jest/transform/file.transform.js',
'^.+\\.tsx?$': '<rootDir>/config/jest/transform/typescript.transform.js'
},
moduleFileExtensions: [
'web.ts',
'ts',
'tsx',
'web.js',
'js',
'json',
'node'
],
globals: {
'ts-jest': {
tsConfig: 'tsconfig.spec.json'
}
},
coverageThreshold: {
global: {
branches: 100,
functions: 100,
lines: 100,
statements: 100
}
}
};