forked from DestinyItemManager/DIM
-
Notifications
You must be signed in to change notification settings - Fork 0
/
jest.config.js
31 lines (31 loc) · 1.01 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
module.exports = {
testEnvironment: 'jsdom',
reporters: ['default', 'jest-junit'],
verbose: true,
testTimeout: 60000,
moduleNameMapper: {
'\\.(jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$':
'<rootDir>/src/__mocks__/fileMock.js',
'^app/(.*)$': '<rootDir>/src/app/$1',
'^data/(.*)$': '<rootDir>/src/data/$1',
'^images/(.*)$': '<rootDir>/src/images/$1',
'^locale/(.*)$': '<rootDir>/src/locale/$1',
'^testing/(.*)$': '<rootDir>/src/testing/$1',
'^docs/(.*)$': '<rootDir>/docs/$1',
'^.+\\.s?css$': 'identity-obj-proxy',
'Library\\.mjs$': 'identity-obj-proxy',
},
setupFiles: ['./src/testing/jest-setup.js'],
// Babel transform is required to handle some es modules?
transformIgnorePatterns: ['node_modules/(?!bungie-api-ts|@popper|@react-hook)'],
globals: {
$BROWSERS: [],
$DIM_FLAVOR: 'test',
$DIM_WEB_API_KEY: 'xxx',
$DIM_API_KEY: 'xxx',
$DIM_VERSION: '1.0.0',
$featureFlags: {
dimApi: true,
},
},
};