mirror of
https://github.com/status-im/react-navigation.git
synced 2025-02-24 17:18:09 +00:00
22 lines
575 B
JavaScript
22 lines
575 B
JavaScript
/* @flow */
|
|
|
|
// See https://github.com/facebook/jest/issues/2208
|
|
jest.mock('Linking', () => {
|
|
return {
|
|
addEventListener: jest.fn(),
|
|
removeEventListener: jest.fn(),
|
|
openURL: jest.fn(),
|
|
canOpenURL: jest.fn(),
|
|
getInitialURL: jest.fn().mockImplementation((value: string) => Promise.resolve(value)),
|
|
}
|
|
});
|
|
|
|
// See https://github.com/facebook/react-native/issues/11659
|
|
jest.mock('ScrollView', () => {
|
|
const RealComponent = require.requireActual('ScrollView');
|
|
class ScrollView extends RealComponent {
|
|
scrollTo = () => {}
|
|
}
|
|
return ScrollView
|
|
});
|