2017-12-22 04:16:14 +08:00
|
|
|
module.exports = {
|
2017-12-16 06:36:26 +08:00
|
|
|
moduleNameMapper: {
|
|
|
|
'^i18n!(.*$)': '<rootDir>/jest/i18nTransformer.js',
|
2018-01-13 01:25:40 +08:00
|
|
|
'^compiled/(.*)$': '<rootDir>/app/coffeescripts/$1',
|
|
|
|
'^jsx/(.*)$': '<rootDir>/app/jsx/$1'
|
2017-12-22 04:16:14 +08:00
|
|
|
},
|
2017-12-16 06:36:26 +08:00
|
|
|
roots: ['app/jsx'],
|
2018-01-13 01:25:40 +08:00
|
|
|
moduleDirectories: [
|
|
|
|
'node_modules',
|
|
|
|
'public/javascripts',
|
|
|
|
'public/javascripts/vendor'
|
|
|
|
],
|
2018-07-11 02:58:17 +08:00
|
|
|
reporters: [ "default", "jest-junit" ],
|
2018-01-13 01:25:40 +08:00
|
|
|
setupFiles: [
|
2018-02-07 06:34:04 +08:00
|
|
|
'jest-localstorage-mock',
|
2018-01-13 01:25:40 +08:00
|
|
|
'<rootDir>/jest/jest-setup.js'
|
|
|
|
],
|
2018-03-06 10:23:07 +08:00
|
|
|
testMatch: [
|
|
|
|
'**/__tests__/**/?(*.)(spec|test).js'
|
|
|
|
],
|
2017-12-16 06:36:26 +08:00
|
|
|
transform: {
|
|
|
|
'^i18n': '<rootDir>/jest/i18nTransformer.js',
|
|
|
|
'^.+\\.jsx?$': 'babel-jest'
|
2018-01-13 01:25:40 +08:00
|
|
|
}
|
2017-12-22 04:16:14 +08:00
|
|
|
}
|