コード例 #1
0
 /// <summary>
 /// Convenience method for wrapping up the standard WebDriverWait construction.
 /// </summary>
 /// <param name="driver">The relevant driver instance.</param>
 /// <param name="message">The message to display upon timeout.</param>
 /// <param name="timeout">The length of time in seconds to poll for the condition.</param>
 /// <returns>The WebDriverWait instance</returns>
 /// <example>
 /// <code>
 /// driver.Wait().Until(d => checkbox.Displayed);
 /// </code>
 /// </example>
 public static WebDriverWait Wait(this IWebDriver driver, string message, int timeout = 5)
 {
     return(WebDriverSupport.Wait(driver, message, timeout));
 }
コード例 #2
0
        //public static Retry Retry(this IWebDriver driver, int maxRetries = 5)
        //{
        //    return new Retry(driver, maxRetries);
        //}

        #region "Driver-centric Utils refs"

        /// <summary>
        /// Convenience method for wrapping up the standard WebDriverWait construction.
        /// </summary>
        /// <param name="driver">The relevant driver instance.</param>
        /// <param name="timeout">The length of time in seconds to poll for the condition.</param>
        /// <returns>The WebDriverWait instance</returns>
        /// <example>
        /// <code>
        /// driver.Wait().Until(d => checkbox.Displayed);
        /// </code>
        /// </example>
        public static WebDriverWait Wait(this IWebDriver driver, int timeout = 5)
        {
            return(WebDriverSupport.Wait(driver, timeout));
        }