mirror of
https://github.com/zhigang1992/create-react-app.git
synced 2026-04-23 04:40:23 +08:00
Allow popular test path conventions (#400)
This commit is contained in:
@@ -20,6 +20,12 @@ module.exports = (resolve, rootDir) => {
|
||||
resolve('config/polyfills.js')
|
||||
],
|
||||
setupTestFrameworkScriptFile: resolve('config/jest/environment.js'),
|
||||
testPathIgnorePatterns: ['<rootDir>/node_modules/', '<rootDir>/build/'],
|
||||
// Allow three popular conventions:
|
||||
// **/__tests__/*.js
|
||||
// **/*.test.js
|
||||
// **/*.spec.js
|
||||
testRegex: '(__tests__/.*|\\.(test|spec))\\.js$',
|
||||
testEnvironment: 'node',
|
||||
verbose: true
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user