mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-25 11:14:01 +00:00
Fix the space exploration UI test on iPad
The tab rail used in regular width on iPad is a custom view and never applied the tabs' accessibility identifiers, so UI tests couldn't find its buttons. Apply them to the rail's buttons the same way the TabView layout does.
This commit is contained in:
@@ -450,6 +450,7 @@ struct TabRailView<Tag: Hashable>: View {
|
|||||||
}
|
}
|
||||||
.buttonStyle(TabButtonStyle(isSelected: isSelected))
|
.buttonStyle(TabButtonStyle(isSelected: isSelected))
|
||||||
.accessibilityAddTraits(isSelected ? .isSelected : [])
|
.accessibilityAddTraits(isSelected ? .isSelected : [])
|
||||||
|
.accessibilityIdentifier(module.details.accessibilityIdentifier ?? "")
|
||||||
.overlay(alignment: .topTrailing) {
|
.overlay(alignment: .topTrailing) {
|
||||||
if module.details.badgeCount > 0 {
|
if module.details.badgeCount > 0 {
|
||||||
NotificationCountBadge(count: module.details.badgeCount, size: .small)
|
NotificationCountBadge(count: module.details.badgeCount, size: .small)
|
||||||
|
|||||||
Reference in New Issue
Block a user