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:
Stefan Ceriu
2026-10-16 09:39:50 +03:00
parent 734c0678fa
commit 87f6b1379b
@@ -450,6 +450,7 @@ struct TabRailView<Tag: Hashable>: View {
}
.buttonStyle(TabButtonStyle(isSelected: isSelected))
.accessibilityAddTraits(isSelected ? .isSelected : [])
.accessibilityIdentifier(module.details.accessibilityIdentifier ?? "")
.overlay(alignment: .topTrailing) {
if module.details.badgeCount > 0 {
NotificationCountBadge(count: module.details.badgeCount, size: .small)