2022-10-08 13:22:44 +02:00
|
|
|
// to run tests with ES6 module, node must run with "--experimental-vm-modules", or see Makefile's "test-frontend" for reference
|
2021-04-08 12:41:57 +02:00
|
|
|
export default {
|
2021-08-17 07:32:48 +02:00
|
|
|
rootDir: 'web_src',
|
2021-10-19 09:23:58 +02:00
|
|
|
setupFilesAfterEnv: ['jest-extended/all'],
|
2022-08-23 14:58:04 +02:00
|
|
|
testEnvironment: 'jest-environment-jsdom',
|
2021-08-17 07:32:48 +02:00
|
|
|
testMatch: ['<rootDir>/**/*.test.js'],
|
2021-04-08 12:41:57 +02:00
|
|
|
testTimeout: 20000,
|
2021-11-16 09:16:05 +01:00
|
|
|
transform: {
|
2022-05-10 21:44:36 +02:00
|
|
|
'\\.svg$': '<rootDir>/js/testUtils/jestRawLoader.js',
|
2021-11-16 09:16:05 +01:00
|
|
|
},
|
2022-10-08 13:22:44 +02:00
|
|
|
setupFiles: [
|
|
|
|
'./js/testUtils/jestSetup.js', // prepare global variables used by our code (eg: window.config)
|
|
|
|
],
|
2021-04-08 12:41:57 +02:00
|
|
|
verbose: false,
|
|
|
|
};
|