Fix concatenation of accessibility labels in automated tests on iOS #24113
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.
Summary
When using Appium in order to provide automated tests a unique accessibility label has to be specified for a single element in order to be identified in the Appium inspector tool. However, on iOS, the accessibility label for a single element contained the labels of all the elements on the screen concatenated into one string.
I have provided a fix that would stop concatenating the accessibility labels of other elements from the screen.
Changelog
[IOS][Changed] - Fix concatenation of accessibilityLabels for an element
Test Plan
Before the fix, the accessibility labels were showing like this in the Appium inspector.
https://ibb.co/Nxq4Cdh
I have run the following tests in order to make sure that the current modifications are working and that the old functionality is still working.