forked from content-services/content-sources-frontend
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathjest.config.js
24 lines (23 loc) · 857 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
module.exports = {
roots: ['<rootDir>/src/'],
preset: 'ts-jest',
testEnvironment: 'jsdom',
transform: {
'^.+\\.(t)s$': 'ts-jest',
'^.+\\.(css|scss|sass|less)$': 'jest-preview/transforms/css',
'^(?!.*\\.(js|jsx|mjs|cjs|ts|tsx|css|json)$)': 'jest-preview/transforms/file',
},
setupFiles: [],
setupFilesAfterEnv: ['<rootDir>/config/setupAfterEnv.ts'],
moduleDirectories: ['<rootDir>/node_modules', '<rootDir>/src'],
// Below replaces things for speed
moduleNameMapper: {
'\\.(jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$':
'<rootDir>/config/empty.js',
'\\.(svg)$': 'identity-obj-proxy',
'^uuid$': require.resolve('uuid'),
},
transformIgnorePatterns: [
// '<rootDir>/node_modules/(?!@redhat-cloud-services|@openshift|lodash-es|uuid|@patternfly/react-icons)',
],
};