Skip to content

Commit

Permalink
Revert "Don't validate arrival on goTo testing helper function"
Browse files Browse the repository at this point in the history
This reverts commit 4caeda6.
  • Loading branch information
nriedman committed Sep 4, 2024
1 parent 021d5f0 commit 599b4d8
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions ENGAGEHFUITests/HelperFunctions/XCUIApplication+GoTo.swift
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,11 @@ import XCTest


extension XCUIApplication {
/// Tries to navigate to a tab by clicking on a button in the current view with label `tabName`
func goTo(tab tabName: String) throws {
/// Tries to navigate to a tab by clicking on a button in the current view with label "id", and verifies the correct arrival by looking for a header with label "header" or "id" if no header given.
func goTo(tab tabName: String, header: String? = nil) throws {
XCTAssert(buttons[tabName].waitForExistence(timeout: 1.0), "No button found for tab \(tabName)")
buttons[tabName].tap()
swipeDown()
XCTAssert(staticTexts[header ?? tabName].waitForExistence(timeout: 1.0))
}
}

0 comments on commit 599b4d8

Please sign in to comment.