Skip to content

Instantly share code, notes, and snippets.

@thecb4
Last active January 2, 2019 21:13
Show Gist options
  • Save thecb4/d3d8649ba56b10f6342da459f32d2a73 to your computer and use it in GitHub Desktop.
Save thecb4/d3d8649ba56b10f6342da459f32d2a73 to your computer and use it in GitHub Desktop.
UIElement protocol to abstract away XCUIElement to align with app behavior
protocol UIElement {
var existance: ApplicationState { get }
}
protocol Application {
static var app: Application { get }
var searchBar: UIElement { get }
var movieTable: UIElement { get }
func movie(titled: String) -> UIElement
func moviePoster(titled: String) -> UIElement
func comments(containing text: String) -> [UIElement]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment