Mocks: fix button content missing#4048
Merged
m-bert merged 5 commits intosoftware-mansion:v2-stablefrom Apr 2, 2026
Merged
Conversation
…#4039) ## Description Current logic dedicated to handling `RNRootViewGestureRecognizer` on iOS looks only for RN's native roots. When gestures are used inside Screens' `FullWindowOverlay`, the logic doesn't do anything, but the overlay has its own [`RCTSurfaceTouchHandler`](https://github.com/software-mansion/react-native-screens/blob/be64b6d9a17c3a4647806f252e075b96b9f690cc/ios/RNSFullWindowOverlay.mm#L158). This PR updates the traversal logic so it handles `RNSFullWindowOverlayContainer` the same way as `RCTSurfaceView`. ## Test plan I wasn't able to reproduce the problem, but in theory, it's possible that without this change, recognizers from RNGH and RCTSurfaceTouchHandler could run simultaneously, since this path never ran: https://github.com/software-mansion/react-native-gesture-handler/blob/5587435679eabe3f8690f077ba7c2ecc3e354a14/packages/react-native-gesture-handler/apple/RNRootViewGestureRecognizer.m#L55-L63
This makes it impossible for tests to target a button based on displayed elements.
Co-authored-by: Michał Bert <63123542+m-bert@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Lacking button content in the provided mocks makes it impossible to write tests such as "is the button with 'foo' rendered" or "press the button with 'bar'".
Test plan