Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- const useMock : any = [(k: any) => k, {}];
- useMock.t = (k: any) => k;
- useMock.i18n = {};
- jest.mock('react-i18next', () => ({
- // this mock makes sure any components using the translate HoC receive the t function as a prop
- /* tslint:disable-next-line:variable-name */
- useTranslation: () => useMock,
- }));
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement