Skip to content

Conversation

@m-bert
Copy link
Contributor

@m-bert m-bert commented Nov 25, 2025

Description

This PR adds handling of testID property.

Test plan

yarn test api_v3

@m-bert m-bert changed the base branch from next to @mbert/components-new-api November 25, 2025 15:45
Comment on lines 31 to 35
if (key === 'testID') {
res.gestureHandlerProps[key] = props[key];
// @ts-ignore FIXME(TS)
res.childProps[key] = props[key];
}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The idea here is to use the same testID for both, component and gesture. This way, it is possible to use getByGestureTestId, which returns gesture, and locate component by the same ID (though I have not tested that with other testing tools).

If you can see that this fails, let me know.

Co-authored-by: Jakub Piasecki <jakub.piasecki@swmansion.com>
Base automatically changed from @mbert/components-new-api to next December 3, 2025 16:05
@m-bert m-bert requested a review from j-piasecki December 4, 2025 10:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants