-
Notifications
You must be signed in to change notification settings - Fork 0
/
jest.config.js
32 lines (32 loc) · 879 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
module.exports = {
preset: "ts-jest",
globals: {
"ts-jest": {
babelConfig: true,
},
},
snapshotSerializers: ["@emotion/jest/serializer"],
testMatch: ["**/**.test.{ts,tsx}"],
setupFilesAfterEnv: ["<rootDir>/setupTests.ts"],
testPathIgnorePatterns: ["<rootDir>/.next/", "<rootDir>/node_modules/"],
moduleFileExtensions: ["ts", "tsx", "js", "jsx"],
modulePaths: ["<rootDir>"],
testURL: "http://localhost",
moduleNameMapper: {
"\\.svg": "<rootDir>/testMocks.ts",
"\\.(css|jpg|png)$": "<rootDir>/empty-module.js",
"^.+\\.(ts|tsx)?$": "ts-jest",
},
moduleDirectories: ["node_modules", "./src"],
notify: true,
notifyMode: "always",
collectCoverageFrom: ["**/*.{ts,tsx}", "!<rootDir>/node_modules/"],
coverageThreshold: {
global: {
statements: 0,
branches: 0,
functions: 0,
lines: 0,
},
},
};