forked from ManageIQ/manageiq-ui-classic
-
Notifications
You must be signed in to change notification settings - Fork 0
/
jest.config.js
27 lines (26 loc) · 675 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
// jest.config.js
const resolveModule = (name) => `<rootDir>/node_modules/${name}`;
module.exports = {
verbose: true,
globals: {
__testing__: true,
getJSONFixture: true,
},
roots: ['app/javascript'],
setupFiles: ['./config/jest.setup.js'],
testRegex: '(/__tests__/.*|(\\.|_|/)(test|spec))\\.jsx?$',
testURL: 'http://localhost',
transform: {
'^.+\\.jsx?$': 'babel-jest',
},
moduleFileExtensions: [
'js',
'jsx',
'json',
],
moduleNameMapper: {
"\\.(css|scss)$": 'identity-obj-proxy',
'^react$': '<rootDir>/node_modules/react/',
'^moment$': resolveModule('moment'), // fix moment-strftime peerDependency issue
},
};