react-native-macos/jest
Rubén Norte 249b8d21c4 Fix inline requires for ESM in react-native-github
Summary:
This fixes how ES modules are handled in Jest tests in the react-native codebase.

They caused some problems before because `import` statements weren't inlined as `require` calls were, so there were some errors in tests when migrating from CommonJS to ESM.

This changes the transform that Jest uses to inline import statements the same way, so we can migrate everything without issues in tests.

Changelog: [Internal]

Reviewed By: kacieb

Differential Revision: D28899692

fbshipit-source-id: 027690f57ca3b5613c261a1089c0635af76662b2
2021-06-04 13:05:11 -07:00
..
MockNativeMethods.js change jest native method mocks to jest functions (#24337) 2019-04-07 11:54:48 -07:00
assetFileTransformer.js Remove `fbjs-scripts` in favor of `@jest/create-cache-key-function` 2020-10-06 18:22:58 -07:00
mockComponent.js Correctly mock all components by setting the displayName 2020-07-28 13:09:06 -07:00
mockNativeComponent.js RN: Create `NativeComponentRegistry` 2020-11-19 10:55:50 -08:00
mockScrollView.js Make ScrollView use ForwardRef 2020-03-26 16:53:46 -07:00
preprocessor.js Fix inline requires for ESM in react-native-github 2021-06-04 13:05:11 -07:00
renderer.js Update FlowFixMes to use error codes in react-native-github 2021-03-31 18:21:47 -07:00
setup.js RN][JS][static view configs] Use unstable_hasStaticViewConfig to detect if a component is registered in the native app 2021-04-30 17:41:25 -07:00