forked from achievements-app/psn-api
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathjest.config.js
47 lines (46 loc) · 1.04 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
module.exports = {
roots: ["<rootDir>"],
moduleFileExtensions: ["ts", "tsx", "js", "json", "jsx"],
testPathIgnorePatterns: [
"<rootDir>[/\\\\](node_modules|.next|cypress)[/\\\\]"
],
transformIgnorePatterns: ["[/\\\\]node_modules[/\\\\].+\\.(ts|tsx)$"],
projects: [
{
displayName: {
name: "UNIT",
color: "blue"
},
testMatch: ["<rootDir>/src/**/*.test.ts"],
transform: {
"^.+\\.(ts|tsx)$": "ts-jest"
},
coverageThreshold: {
global: {
branches: 75,
functions: 100,
lines: 100,
statements: 100
}
},
collectCoverageFrom: [
"src/**/*.{ts,tsx}",
"!src/**/*.model.ts",
"!src/**/index.ts",
"!src/test/**/*.ts",
"!src/__playground.ts"
]
},
{
displayName: {
name: "E2E",
color: "magenta"
},
testMatch: ["<rootDir>/e2e/**/*.e2e.spec.ts"],
transform: {
"^.+\\.(ts|tsx)$": "ts-jest"
},
maxWorkers: 1
}
]
};