From d109f0eeba03a9e84989a00c411c47a84c3e532e Mon Sep 17 00:00:00 2001 From: Steffen Kleinle Date: Mon, 18 Nov 2024 09:38:54 +0100 Subject: [PATCH] 1010: Fix tests --- jest.setup.ts | 2 -- package.json | 2 +- src/__tests__/App.spec.tsx | 2 +- src/routes/home/components/ProfessionDetails.tsx | 2 +- 4 files changed, 3 insertions(+), 5 deletions(-) diff --git a/jest.setup.ts b/jest.setup.ts index ae8f52e5..f5cc54b3 100644 --- a/jest.setup.ts +++ b/jest.setup.ts @@ -15,8 +15,6 @@ jest.mock('react-native-reanimated', () => { return Reanimated }) -// Silence the warning: Animated: `useNativeDriver` is not supported because the native animated module is missing -jest.mock('react-native/Libraries/Animated/NativeAnimatedHelper') jest.mock('react-native/Libraries/EventEmitter/NativeEventEmitter') jest.mock('@react-native-async-storage/async-storage', () => mockAsyncStorage) diff --git a/package.json b/package.json index bf7cad5b..e48a27a2 100644 --- a/package.json +++ b/package.json @@ -5,7 +5,7 @@ "packageManager": "yarn@3.2.2", "scripts": { "android": "react-native run-android --no-packager --active-arch-only", - "android:production": "react-native run-android --no-packager --variant=release", + "android:production": "react-native run-android --no-packager --mode=release", "ios": "react-native run-ios", "start": "react-native start", "test": "jest --verbose --maxWorkers=1", diff --git a/src/__tests__/App.spec.tsx b/src/__tests__/App.spec.tsx index 3539b64b..7993e810 100644 --- a/src/__tests__/App.spec.tsx +++ b/src/__tests__/App.spec.tsx @@ -5,7 +5,7 @@ import { View } from 'react-native' import App from '../App' jest.mock('react-navigation-header-buttons', () => ({ - OverflowMenuProvider: ({ children }: { children: ReactNode }) => {children}, + HeaderButtonsProvider: ({ children }: { children: ReactNode }) => {children}, })) jest.mock('../navigation/Navigator', () => { const Text = require('react-native').Text diff --git a/src/routes/home/components/ProfessionDetails.tsx b/src/routes/home/components/ProfessionDetails.tsx index cade6d32..70491288 100644 --- a/src/routes/home/components/ProfessionDetails.tsx +++ b/src/routes/home/components/ProfessionDetails.tsx @@ -53,7 +53,7 @@ const ProfessionDetails = ({ <>