Пример #1
0
 /// <summary>
 ///     Waits for an element to be visible
 /// </summary>
 /// <param name="driver"></param>
 /// <param name="by"></param>
 /// <param name="timeout">Optional default timeout override</param>
 /// <returns></returns>
 public static bool CheckElementIsVisible(this IWebDriver driver, By by, int?timeout = null)
 {
     return(driver.Check(by, ElementIsVisible(by), timeout: timeout));
 }
Пример #2
0
 /// <summary>
 ///     Waits for an element to be clickable(visible AND enabled)
 ///     Takes into account a predefined timeout
 ///     Preferred method to be used for determining whether a page has been loaded
 ///     See for example all Page Object constructors
 /// </summary>
 /// <param name="driver"></param>
 /// <param name="by"></param>
 /// <param name="timeout">Optional default timeout override</param>
 /// <returns></returns>
 public static bool WaitForElementOnPageLoad(this IWebDriver driver, By by, int?timeout = null)
 {
     return(driver.Check(by, ElementToBeClickable(by), timeout: timeout));
 }