CreateDefaultService() public static method

Creates a default instance of the ChromeDriverService.
public static CreateDefaultService ( ) : ChromeDriverService
return ChromeDriverService
Esempio n. 1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ChromeDriver"/> class using the specified options.
 /// </summary>
 /// <param name="options">The <see cref="ChromeOptions"/> to be used with the Chrome driver.</param>
 public ChromeDriver(ChromeOptions options)
     : this(ChromeDriverService.CreateDefaultService(), options, RemoteWebDriver.DefaultCommandTimeout)
 {
 }
Esempio n. 2
0
 /// <summary>
 /// Initializes a new instance of the ChromeDriver class using the specified options.
 /// </summary>
 /// <param name="options">The <see cref="ChromeOptions"/> to be used with the Chrome driver.</param>
 public ChromeDriver(ChromeOptions options)
     : this(ChromeDriverService.CreateDefaultService(), options, TimeSpan.FromSeconds(60))
 {
 }
Esempio n. 3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ChromeDriver"/> class using the specified path
 /// to the directory containing ChromeDriver.exe, options, and command timeout.
 /// </summary>
 /// <param name="chromeDriverDirectory">The full path to the directory containing ChromeDriver.exe.</param>
 /// <param name="options">The <see cref="ChromeOptions"/> to be used with the Chrome driver.</param>
 /// <param name="commandTimeout">The maximum amount of time to wait for each command.</param>
 public ChromeDriver(string chromeDriverDirectory, ChromeOptions options, TimeSpan commandTimeout)
     : this(ChromeDriverService.CreateDefaultService(chromeDriverDirectory), options, commandTimeout)
 {
 }
Esempio n. 4
0
 /// <summary>
 /// Initializes a new instance of the ChromeDriver class using the capabilities.
 /// </summary>
 /// <param name="capabilities">The desired capabilities of the Chrome driver.</param>
 public ChromeDriver(ICapabilities capabilities)
     : this(ChromeDriverService.CreateDefaultService(), capabilities, TimeSpan.FromSeconds(60))
 {
 }
Esempio n. 5
0
 /// <summary>
 /// Initializes a new instance of the ChromeDriver class using the specified path to the directory containing ChromeDriver.exe and capabilities.
 /// </summary>
 /// <param name="chromeDriverDirectory">The full path to the directory containing ChromeDriver.exe.</param>
 /// <param name="capabilities">The desired capabilities of the Chrome driver.</param>
 public ChromeDriver(string chromeDriverDirectory, ICapabilities capabilities)
     : this(ChromeDriverService.CreateDefaultService(chromeDriverDirectory), capabilities, TimeSpan.FromSeconds(60))
 {
 }
Esempio n. 6
0
 /// <summary>
 /// Initializes a new instance of the ChromeDriver class.
 /// </summary>
 public ChromeDriver()
     : this(ChromeDriverService.CreateDefaultService(), DesiredCapabilities.Chrome(), TimeSpan.FromSeconds(60))
 {
 }
Esempio n. 7
0
 /// <summary>
 /// Initializes a new instance of the ChromeDriver class using the specified path to the directory containing ChromeDriver.exe, command timeout, and capabilities.
 /// </summary>
 /// <param name="chromeDriverDirectory">The full path to the directory containing ChromeDriver.exe.</param>
 /// <param name="capabilities">The desired capabilities of the Chrome driver.</param>
 /// <param name="commandTimeout">The maximum amount of time to wait for each command.</param>
 public ChromeDriver(string chromeDriverDirectory, ICapabilities capabilities, TimeSpan commandTimeout)
     : this(ChromeDriverService.CreateDefaultService(chromeDriverDirectory), capabilities, commandTimeout)
 {
 }
Esempio n. 8
0
 /// <summary>
 /// Initializes a new instance of the ChromeDriver class.
 /// </summary>
 public ChromeDriver()
     : this(ChromeDriverService.CreateDefaultService(), TimeSpan.FromSeconds(60))
 {
 }
 public static ChromeDriverService CreateDefaultService(string driverPath)
 {
     return(ChromeDriverService.CreateDefaultService(driverPath, ChromeDriverService.ChromeDriverServiceFileName()));
 }
        public static ChromeDriverService CreateDefaultService()
        {
            string driverPath = DriverService.FindDriverServiceExecutable(ChromeDriverService.ChromeDriverServiceFileName(), ChromeDriverService.ChromeDriverDownloadUrl);

            return(ChromeDriverService.CreateDefaultService(driverPath));
        }