Refactor Open Profile (#8746)

* Refactor Open Profile

* Add missing changes

* Fix tests

* Fix tests

* Address feedback
This commit is contained in:
Daniel Espino García
2025-05-13 17:07:13 +02:00
committed by GitHub
parent 305fbee513
commit af0a7525c8
89 changed files with 509 additions and 270 deletions

View File

@@ -94,6 +94,7 @@ jest.doMock('react-native', () => {
InteractionManager: RNInteractionManager,
NativeModules: RNNativeModules,
Linking: RNLinking,
Keyboard: RNKeyboard,
} = ReactNative;
const Alert = {
@@ -250,6 +251,14 @@ jest.doMock('react-native', () => {
}),
};
const Keyboard = {
...RNKeyboard,
dismiss: jest.fn(),
addListener: jest.fn(() => ({
remove: jest.fn(),
})),
};
return Object.setPrototypeOf({
Platform: {
...Platform,
@@ -270,6 +279,7 @@ jest.doMock('react-native', () => {
InteractionManager,
NativeModules,
Linking,
Keyboard,
Animated: {
...ReactNative.Animated,
timing: jest.fn(() => ({
@@ -393,6 +403,7 @@ jest.mock('react-native-share', () => ({
}));
jest.mock('@screens/navigation', () => ({
...jest.requireActual('@screens/navigation'),
resetToChannel: jest.fn(),
resetToSelectServer: jest.fn(),
resetToTeams: jest.fn(),