You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

17 lines
475 B

3 years ago
  1. import { NativeModules } from 'react-native';
  2. // to address https://github.com/facebook/react-native/issues/27721
  3. jest.mock(
  4. 'react-native/Libraries/Components/Touchable/TouchableOpacity',
  5. () => {
  6. const TouchableOpacity = jest.requireActual(
  7. 'react-native/Libraries/Components/Touchable/TouchableOpacity'
  8. );
  9. TouchableOpacity.displayName = 'TouchableOpacity';
  10. return TouchableOpacity;
  11. }
  12. );
  13. NativeModules.ReactLocalization = { language: 'en' };