diff --git a/PediFoodsUITests/CartCheckoutFlowTests.swift b/PediFoodsUITests/CartCheckoutFlowTests.swift index d13cd86..a8a9497 100644 --- a/PediFoodsUITests/CartCheckoutFlowTests.swift +++ b/PediFoodsUITests/CartCheckoutFlowTests.swift @@ -106,8 +106,8 @@ final class CartCheckoutFlowTests: XCTestCase { app.swipeDown() } if app.staticTexts["Finalizar Pedido"].waitForExistence(timeout: 10) == false { - let dir = "/private/tmp/claude-501/-Users-loverde-co-Documents-Loverde-JOBs-Producao-Loverde-Co-LC-RAG-Struct-projects-PediFoods-ios/4a9ec4f7-c3ad-4cf5-8dad-073446f6fd81/scratchpad" - try? app.screenshot().pngRepresentation.write(to: URL(fileURLWithPath: "\(dir)/after_alterar_dismiss.png")) + print("=== Never returned to Checkout after Alterar dismiss - accessibility hierarchy ===") + print(app.debugDescription) } XCTAssertTrue(app.staticTexts["Finalizar Pedido"].exists, "Never returned to Checkout") @@ -180,8 +180,8 @@ final class CartCheckoutFlowTests: XCTestCase { // a plain static text. let storeCard = app.buttons.matching(NSPredicate(format: "label CONTAINS[c] %@", "MARIBA")).firstMatch if storeCard.waitForExistence(timeout: 15) == false { - let dir = "/private/tmp/claude-501/-Users-loverde-co-Documents-Loverde-JOBs-Producao-Loverde-Co-LC-RAG-Struct-projects-PediFoods-ios/4a9ec4f7-c3ad-4cf5-8dad-073446f6fd81/scratchpad" - try? app.screenshot().pngRepresentation.write(to: URL(fileURLWithPath: "\(dir)/no_store_card.png")) + print("=== No MARIBA store card on Home - accessibility hierarchy ===") + print(app.debugDescription) } XCTAssertTrue(storeCard.exists, "Expected store card never appeared on Home") storeCard.tap() @@ -201,8 +201,15 @@ final class CartCheckoutFlowTests: XCTestCase { // directly instead - same fix pattern as the cart-tab icon. let addButton = app.images.matching(identifier: "plus").firstMatch if addButton.waitForExistence(timeout: 25) == false { - let dir = "/private/tmp/claude-501/-Users-loverde-co-Documents-Loverde-JOBs-Producao-Loverde-Co-LC-RAG-Struct-projects-PediFoods-ios/4a9ec4f7-c3ad-4cf5-8dad-073446f6fd81/scratchpad" - try? app.screenshot().pngRepresentation.write(to: URL(fileURLWithPath: "\(dir)/store_detail_timeout40.png")) + // A hardcoded scratch-path screenshot write here was silently + // no-oping on the CI runner (try? swallowed a write failure + // into a directory that doesn't exist on this machine's user + // account) - printing the accessibility hierarchy instead + // shows up directly in the CI log with no extra file access + // needed, same technique already used in + // decisions/2026-08-06-ui-test-account-and-app-attest-bypass.md. + print("=== Store Detail timeout - accessibility hierarchy ===") + print(app.debugDescription) } XCTAssertTrue(addButton.exists, "Store Detail's product list never loaded") addButton.tap()