コード例 #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="WebDriverCommandProcessor"/> class.
 /// </summary>
 /// <param name="baseUrl">The base URL of the Selenium server.</param>
 /// <param name="baseDriver">The IWebDriver object used for executing commands.</param>
 public WebDriverCommandProcessor(Uri baseUrl, IWebDriver baseDriver)
 {
     this.driver = baseDriver;
     this.baseUrl = baseUrl;
     this.select = new SeleniumOptionSelector(this.elementFinder);
     this.timer = new CommandTimer(30000);
     this.alertOverride = new AlertOverride(baseDriver);
 }
コード例 #2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="WebDriverCommandProcessor"/> class.
        /// </summary>
        /// <param name="baseUrl">The base URL of the Selenium server.</param>
        /// <param name="baseDriver">The IWebDriver object used for executing commands.</param>
        public WebDriverCommandProcessor(Uri baseUrl, IWebDriver baseDriver)
        {
            if (baseUrl == null)
            {
                throw new ArgumentNullException("baseUrl", "baseUrl cannot be null");
            }

            this.driver = baseDriver;
            this.baseUrl = baseUrl;
            this.mutator = new CompoundMutator(baseUrl.ToString());
            this.timer = new CommandTimer(30000);
            this.alertOverride = new AlertOverride(baseDriver);
        }