diff --git a/CHANGELOG.md b/CHANGELOG.md index 01f3284eb17e..bf804295d94e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -27,6 +27,7 @@ - `[jest-haste-map]` Don't use partial results if file crawl errors ([#12420](https://github.com/facebook/jest/pull/12420)) - `[jest-jasmine2, jest-types]` [**BREAKING**] Move all `jasmine` specific types from `@jest/types` to its own package ([#12125](https://github.com/facebook/jest/pull/12125)) - `[jest-matcher-utils]` Pass maxWidth to `pretty-format` to avoid printing every element in arrays by default ([#12402](https://github.com/facebook/jest/pull/12402)) +- `[jest-runtime]` Permit tests in node_modules ([#12438](https://github.com/facebook/jest/pull/12438)) ### Chore & Maintenance diff --git a/packages/jest-runtime/src/index.ts b/packages/jest-runtime/src/index.ts index 363eef8f90cb..c3e5958153d6 100644 --- a/packages/jest-runtime/src/index.ts +++ b/packages/jest-runtime/src/index.ts @@ -386,7 +386,7 @@ export default class Runtime { name: config.name, platforms: config.haste.platforms || ['ios', 'android'], resetCache: options?.resetCache, - retainAllFiles: false, + retainAllFiles: true, rootDir: config.rootDir, roots: config.roots, throwOnModuleCollision: config.haste.throwOnModuleCollision,