-
Notifications
You must be signed in to change notification settings - Fork 0
/
jest.config.js
34 lines (24 loc) · 1.19 KB
/
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
33
34
module.exports = {
// Automatically clear mock calls and instances between every test
// clearMocks: true,
// The directory where Jest should output its coverage files
coverageDirectory: 'coverage',
// An array of regexp pattern strings used to skip coverage collection
coveragePathIgnorePatterns: ['/node_modules/'],
moduleFileExtensions: ['js', 'jsx'],
// A list of reporter names that Jest uses when writing coverage reports
coverageReporters: ['text', 'html'],
// A list of paths to directories that Jest should use to search for files in
modulePaths: ['<rootDir>/src'],
setupFilesAfterEnv: ['<rootDir>/config/jest/jest-setup.js'],
// An array of regexp pattern strings that are matched against all test paths, matched tests are skipped
testPathIgnorePatterns: ['/node_modules/'],
// An array of regexp pattern strings that are matched against all source file paths, matched files will skip
// transformation
transformIgnorePatterns: ['/node_modules/'],
snapshotSerializers: ['enzyme-to-json/serializer'],
moduleNameMapper: {
'\\.(jpg|ico|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$':
'<rootDir>/config/jest/file-mock.js'
}
};