-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathjest.config.js
More file actions
30 lines (30 loc) · 830 Bytes
/
jest.config.js
File metadata and controls
30 lines (30 loc) · 830 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
module.exports = {
globals: {
"ts-jest": {
diagnostics: true,
tsConfig: "tsconfig.json"
}
},
// snapshotSerializers: [require("./pretty-format-toJSON")],
collectCoverageFrom: [
"src/models/**/*.ts"
// "src/modules/**/*.ts"
// "src/utils/**/*.ts",
// "src/config/libs/*.ts",
// "src/config/index.ts"
],
moduleFileExtensions: ["ts", "js"],
moduleNameMapper: {
"^@models/(.*)": "<rootDir>/src/models/$1",
"^@modules/(.*)": "<rootDir>/src/modules/$1",
"^@config/(.*)": "<rootDir>/src/config/$1",
"^@utils/(.*)": "<rootDir>/src/utils/$1",
"^types/(.*)": "<rootDir>/src/types/$1"
},
transform: {
"^.+\\.(ts|tsx)$": "ts-jest"
},
testMatch: ["**/test/**/*.test.(ts|js)"],
testEnvironment: "node",
setupTestFrameworkScriptFile: "./jest.setup.js"
};