mirror of
https://github.com/scm-manager/scm-manager.git
synced 2026-01-09 17:12:15 +01:00
Migrate react-i18next translate in ui-tests
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
jest.mock("react-i18next", () => ({
|
||||
// this mock makes sure any components using the translate HoC receive the t function as a prop
|
||||
translate: () => (Component: any) => {
|
||||
withTranslation: () => (Component: any) => {
|
||||
Component.defaultProps = {
|
||||
...Component.defaultProps,
|
||||
t: (key: string) => key
|
||||
|
||||
Reference in New Issue
Block a user