Skip to content

Instantly share code, notes, and snippets.

View AyaAkl25's full-sized avatar

Aya Akl AyaAkl25

View GitHub Profile
@AyaAkl25
AyaAkl25 / async.swift
Created August 28, 2018 16:34
async wait xcuitest
func waitForElementToAppear(_ xcelement: XCUIElement, _ timeout: Double) {
let expectation = XCTKVOExpectation(keyPath: "exists", object: xcelement, expectedValue: true)
XCTWaiter().wait(for: [expectation], timeout: timeout)
}
Given /^I have (\d+) cucumbers in my belly$/ do |cukes|
# Some Ruby code here
end