Skip to content

Commit

Permalink
fix perf test
Browse files Browse the repository at this point in the history
  • Loading branch information
Piotrfj committed Mar 6, 2024
1 parent 04b53b5 commit 22e4bdc
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions tests/perf-test/OptionsSelector.perf-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,20 @@ import _ from 'underscore';
import OptionsSelector from '@src/components/OptionsSelector';
import variables from '@src/styles/variables';

jest.mock('@react-navigation/native', () => {
const actualNav = jest.requireActual('@react-navigation/native');
return {
...actualNav,
useNavigation: () => ({
navigate: jest.fn(),
addListener: () => jest.fn(),
}),
useIsFocused: () => ({
navigate: jest.fn(),
}),
};
});

jest.mock('../../src/components/withLocalize', () => (Component) => {
function WrappedComponent(props) {
return (
Expand Down

0 comments on commit 22e4bdc

Please sign in to comment.