-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathjest.config.js
30 lines (30 loc) · 863 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
module.exports = {
collectCoverageFrom: [
"src/**/*.(ts|tsx)",
"!**/node_modules/**",
"!**/__docs__/**",
"!**/__tests__/*",
],
coverageDirectory: "<rootDir>/.coverage",
coverageReporters: ["lcov", "text", "text-summary"],
coverageThreshold: {
global: {
branches: 95,
functions: 95,
lines: 95,
statements: 95,
},
},
moduleDirectories: ["node_modules", "<rootDir>"],
moduleFileExtensions: ["ts", "tsx", "js", "jsx", "json"],
moduleNameMapper: {
"\\.(css|less|s(c|a)ss)$": "<rootDir>/src/__mocks__/style.ts",
"@/(.*)": "<rootDir>/$1",
},
rootDir: ".",
setupFiles: ["raf/polyfill"],
setupFilesAfterEnv: ["./src/__tests__/setup.ts"],
testMatch: ["**/*.test.ts", "**/*.test.tsx"],
testPathIgnorePatterns: ["/node_modules/", "/examples/"],
transform: { ".(ts|tsx)": "ts-jest" },
};