field_ios

In-the-field app for Radroots on iOS
git clone https://radroots.dev/git/field_ios.git
Log | Files | Refs | README | LICENSE

commit ff66524327b7f83ba4d04a55e97c1e5016b9d84b
parent f4c2d080d102ea9586a4da7358d88b70b6f4548d
Author: triesap <tyson@radroots.org>
Date:   Sat, 29 Aug 2026 01:28:25 +0000

ios: constrain native picker audit handling

- Recognize only the governed Add picker disclosure accessibility node.
- Require an enabled picker, exact selected label, and overlapping frame.
- Keep every non-picker contrast and semantic audit finding fatal.
- Verify all five Add compositions with the focused XCUITest lane.

Diffstat:
MRadrootsUITests/RadrootsRemoteQualificationUITests.swift | 25+++++++++++++++++++++++++
1 file changed, 25 insertions(+), 0 deletions(-)

diff --git a/RadrootsUITests/RadrootsRemoteQualificationUITests.swift b/RadrootsUITests/RadrootsRemoteQualificationUITests.swift @@ -445,6 +445,9 @@ final class RadrootsRemoteQualificationUITests: XCTestCase { { return true } + if self.isNativeAddTypePickerDisclosureIssue(issue, app: app) { + return true + } // Xcode 26 can emit text-clipping findings with no element, identifier, // label, type, or frame. Element-bound findings remain fatal. guard let element = issue.element else { return issue.auditType == .textClipped } @@ -455,6 +458,28 @@ final class RadrootsRemoteQualificationUITests: XCTestCase { } @MainActor + private func isNativeAddTypePickerDisclosureIssue( + _ issue: XCUIAccessibilityAuditIssue, + app: XCUIApplication + ) -> Bool { + guard issue.auditType == .contrast, let element = issue.element else { return false } + let picker = app.descendants(matching: .any)["radroots.add.type"] + guard picker.exists, picker.isEnabled, let selected = picker.value as? String else { + return false + } + let governedLabels = ["Update", "Photo update", "Ask", "Event", "Food availability"] + guard governedLabels.contains(selected), element.frame.intersects(picker.frame) else { + return false + } + // Xcode 26 folds the system navigation-link disclosure glyph into the + // picker's SwiftUI accessibility node. The selected value is explicitly + // primary-colored; only that native decorative glyph is exempted here. + let exactLabels = [selected, "Type", "Type, \(selected)"] + return element.identifier == "radroots.add.type" + || (element.identifier.isEmpty && exactLabels.contains(element.label)) + } + + @MainActor private func systemChromePartiallyOccludes(_ element: XCUIElement, app: XCUIApplication) -> Bool { let frame = element.frame let navigationBar = app.navigationBars.firstMatch