Deprecate jest/preprocessor.js

Summary:
Changelog:
[General][Deprecated] Deprecate the use of `react-native/jest/preprocessor.js` by external projects

The supported method of using Jest in React Native projects is using the [Jest preset](https://jestjs.io/docs/tutorial-react-native) shipped as part of the `react-native` package. Some projects are directly using `preprocessor.js` which is part of the testing setup for the React Native repo itself.

In a future release of React Native, we will stop publishing this file to npm and require projects to switch to the supported preset (or a custom Jest config if necessary).

Reviewed By: GijsWeterings

Differential Revision: D34820086

fbshipit-source-id: 197c33726639e66c6916a244117252e6af11f2f6
This commit is contained in:
Moti Zilberman
2022-03-14 07:40:05 -07:00
committed by Facebook GitHub Bot
parent 5ea50fd549
commit c1e9aa9a27
3 changed files with 146 additions and 106 deletions
+1 -1
View File
@@ -13,7 +13,7 @@ module.exports = {
transform: {
'^.+\\.(bmp|gif|jpg|jpeg|mp4|png|psd|svg|webp)$':
'<rootDir>/jest/assetFileTransformer.js',
'.*': './jest/preprocessor.js',
'.*': './jest/preprocessor_DO_NOT_USE.js',
},
setupFiles: ['./jest/setup.js'],
timers: 'fake',