-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathjest.backend.config.js
27 lines (26 loc) · 1.16 KB
/
jest.backend.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
const paths = require('./scripts/config/paths');
module.exports = {
verbose: true,
collectCoverageFrom: ['src/server/**/*.{ts,tsx,mjs}'],
setupFiles: [
'<rootDir>/node_modules/regenerator-runtime/runtime',
'<rootDir>/scripts/config/polyfills.js',
],
setupTestFrameworkScriptFile: '<rootDir>/scripts/config/jest/setup.js',
testMatch: [
'<rootDir>/src/server/modules/**/*.spec.{ts,tsx,mjs}',
'<rootDir>/src/server/services/**/*.spec.{ts,tsx,mjs}',
'<rootDir>/src/server/services/**/?(*.)(spec|test).{ts,tsx,mjs}',
'<rootDir>/src/server/modules/**/?(*.)(spec|test).{ts,tsx,mjs}',
],
testEnvironment: 'node',
testURL: 'http://localhost',
transform: {
"^.+\\.tsx?$": "<rootDir>/node_modules/ts-jest/preprocessor.js",
'^.+\\.css$': '<rootDir>/scripts/config/jest/cssTransform.js',
'^(?!.*\\.(js|jsx|mjs|css|json)$)': '<rootDir>/scripts/config/jest/fileTransform.js'
},
transformIgnorePatterns: ['[/\\\\]node_modules[/\\\\].+\\.(js|jsx|mjs)$'],
moduleDirectories: paths.resolveModules,
moduleFileExtensions: ['ts', 'json', 'tsx', 'js', 'jsx', 'node', 'mjs'],
};