-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathjest.config.ts
41 lines (40 loc) · 970 Bytes
/
jest.config.ts
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
const ignorePaths = [
"/node_modules/",
"/dist/",
"/tests/",
"jest.config.ts",
"main.ts",
"app.module.ts",
"/src/external/",
"/src/internal/application/configs/",
"/src/internal/application/docs/",
"/src/internal/application/ports/",
]
export default {
preset: 'ts-jest',
testEnvironment: 'node',
transform: {
'^.+\\.(t|j)s$': 'ts-jest',
},
rootDir: ".",
testMatch: [
"**/__tests__/**/*.ts?(x)",
"**/?(*.)+(spec|test).ts?(x)"
],
collectCoverageFrom: ["**/*.ts"],
coverageDirectory: "<rootDir>/coverage",
coverageThreshold: {
global: {
functions: 80,
lines: 80,
statements: 80,
branches: 80,
},
},
coveragePathIgnorePatterns: ignorePaths,
moduleNameMapper: {
"^src/(.*)$": "<rootDir>/src/$1",
"^tests/(.*)$": "<rootDir>/tests/$1"
},
coverageReporters: ["lcov", "text"]
}