-
Notifications
You must be signed in to change notification settings - Fork 0
/
jest.config.js
45 lines (45 loc) · 1003 Bytes
/
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
module.exports = {
preset: "ts-jest",
globals: {
"ts-jest": {
diagnostics: false
}
},
transform: {
"\\.ts$": ["ts-jest"],
"^.+\\.tsx?$": "babel-jest"
},
collectCoverageFrom: [
"<rootDir>/src/**/*.tsx",
"<rootDir>/src/**/*.ts",
"!**/node_modules/**",
"!**/vendor/**"
],
coverageThreshold: {
global: {
branches: 0,
functions: 0,
lines: 0,
statements: 0
}
},
modulePathIgnorePatterns: [
"<rootDir>/setupTests.ts",
"npm-cache",
".npm",
".webpack",
"../build"
],
setupFiles: ["<rootDir>/setupTests.ts"],
verbose: true,
moduleFileExtensions: ["js", "jsx", "json", "ts", "tsx"],
testMatch: ["<rootDir>/src/**/*test.{js,jsx,ts,tsx}"],
transformIgnorePatterns: [
"<rootDir>/node_modules/(?!${esModules})",
"[/\\\\]node_modules[/\\\\].+\\.(js|jsx|ts|tsx)$",
"^.+\\.module\\.(css|sass|scss)$"
],
moduleNameMapper: {
"\\.(css|less|scss|sass)$": "identity-obj-proxy"
}
};