-
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathjest.config.json
49 lines (49 loc) · 1.89 KB
/
jest.config.json
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
48
49
{
"roots": [
"<rootDir>"
],
"setupFilesAfterEnv": [
"<rootDir>/.jest/setup-tests.js"
],
"coverageDirectory": "<rootDir>/.jest/coverage",
"collectCoverageFrom": [
"src/**/*.{js,jsx,ts,tsx}",
"!src/**/*.d.ts"
],
"testMatch": [
"<rootDir>/__tests__/**/*.{js,jsx,ts,tsx}",
"<rootDir>/src/**/*.{spec,test}.{js,jsx,ts,tsx}"
],
"testEnvironment": "jest-environment-jsdom",
"transform": {
"^.+\\.(js|jsx|mjs|cjs|ts|tsx)$": "<rootDir>/node_modules/babel-jest",
"^.+\\.scss$": "jest-scss-transform"
},
"transformIgnorePatterns": [
"[/\\\\]node_modules[/\\\\].+\\.(js|jsx|mjs|cjs|ts|tsx|png|svg)$",
"^.+\\.module\\.(css|sass|scss)$"
],
"moduleNameMapper": {
"\\.(css|sass|scss|png)$": "identity-obj-proxy",
"\\.(jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$": "<rootDir>/.jest/__mocks__/fileMock.js",
"^@\\/components\\/(.*)$": "<rootDir>/src/components/$1",
"^@\\/configs\\/(.*)$": "<rootDir>/src/configs/$1",
"^@\\/enums\\/(.*)$": "<rootDir>/src/enums/$1",
"^@\\/hooks\\/(.*)$": "<rootDir>/src/hooks/$1",
"^@\\/layouts\\/(.*)$": "<rootDir>/src/layouts/$1",
"^@\\/locales\\/(.*)$": "<rootDir>/src/locales/$1",
"^@\\/pages\\/(.*)$": "<rootDir>/src/pages/$1",
"^@\\/services\\/(.*)$": "<rootDir>/src/services/$1",
"^@\\/store\\/(.*)$": "<rootDir>/src/store/$1",
"^@\\/stories\\/(.*)$": "<rootDir>/src/stories/$1",
"^@\\/types\\/(.*)$": "<rootDir>/src/types/$1",
"^@\\/utils\\/(.*)$": "<rootDir>/src/utils/$1",
"^@\\/src\\/(.*)$": "<rootDir>/src/$1",
"^@\\/assets\\/(.*)$": "<rootDir>/public/assets/$1"
},
"watchPlugins": [
"jest-watch-typeahead/filename",
"jest-watch-typeahead/testname"
],
"resetMocks": true
}