-
-
Notifications
You must be signed in to change notification settings - Fork 11
Expand file tree
/
Copy pathjest.config.js
More file actions
20 lines (17 loc) · 652 Bytes
/
jest.config.js
File metadata and controls
20 lines (17 loc) · 652 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
const nextJest = require('next/jest');
const createJestConfig = nextJest({
dir: './',
});
// Add any custom config to be passed to Jest
const customJestConfig = {
moduleDirectories: ['node_modules', '<rootDir>/'],
testEnvironment: 'jest-environment-jsdom',
testPathIgnorePatterns: ['<rootDir>[/\\\\](node_modules|.next)[/\\\\]', '<rootDir>/cypress/'],
moduleNameMapper: {
'\\.(css|less|sass|scss)$': 'identity-obj-proxy',
'\\.(gif|ttf|eot|svg|png)$': '<rootDir>/test/__mocks__/fileMock.js',
},
setupFilesAfterEnv: ['next', './jest-setup-after.ts'],
testTimeout: 10000,
};
module.exports = createJestConfig(customJestConfig);