/// <summary> /// Creates a default instance of the ChromeDriverService using a specified path to the ChromeDriver executable with the given name. /// </summary> /// <param name="driverPath">The directory containing the ChromeDriver executable.</param> /// <param name="driverExecutableFileName">The name of the ChromeDriver executable file.</param> /// <returns>A ChromeDriverService using a random port.</returns> public static ChromeDriverService CreateDefaultService(string driverPath, string driverExecutableFileName) { return(new ChromeDriverService(driverPath, driverExecutableFileName, PortUtilities.FindFreePort())); }
/// <summary> /// Creates a default instance of the InternetExplorerDriverService using a specified path to the IEDriverServer executable with the given name. /// </summary> /// <param name="driverPath">The directory containing the IEDriverServer executable.</param> /// <param name="driverExecutableFileName">The name of the IEDriverServer executable file.</param> /// <returns>A InternetExplorerDriverService using a random port.</returns> public static InternetExplorerDriverService CreateDefaultService(string driverPath, string driverExecutableFileName) { return(new InternetExplorerDriverService(driverPath, driverExecutableFileName, PortUtilities.FindFreePort())); }
public static FirefoxDriverServiceEx CreateDefaultService(string driverPath, string driverExecutableFileName) => new FirefoxDriverServiceEx(driverPath, driverExecutableFileName, PortUtilities.FindFreePort());
private PhantomJSDriverService() : this(FileUtilities.FindFile(PhantomJSDriverServiceFileName), PhantomJSDriverServiceFileName, PortUtilities.FindFreePort()) { }
/// <summary> /// Creates a default instance of the ChromeDriverService using a specified path to the ChromeDriver executable with the given name. /// </summary> /// <param name="driverPath">The directory containing the ChromeDriver executable.</param> /// <param name="driverExecutableFileName">The name of the ChromeDriver executable file.</param> /// <returns>A ChromeDriverService using a random port.</returns> public static ChromeDriverService CreateDefaultService(string driverPath, string driverExecutableFileName, NetworkCredential user = null) { return(new ChromeDriverService(driverPath, driverExecutableFileName, PortUtilities.FindFreePort(), user)); }
/// <summary> /// Creates a default instance of the PhantomJSDriverService using a specified path to the PhantomJS executable. /// </summary> /// <param name="driverPath">The directory containing the PhantomJS executable.</param> /// <returns>A PhantomJSDriverService using a random port.</returns> public static PhantomJSDriverService CreateDefaultService(string driverPath) { return(new PhantomJSDriverService(driverPath, PortUtilities.FindFreePort())); }
/// <summary> /// Creates a default instance of the EdgeDriverService using a specified path to the WebDriver executable with the given name. /// </summary> /// <param name="driverPath">The directory containing the WebDriver executable.</param> /// <param name="driverExecutableFileName">The name of the WebDriver executable file.</param> /// <returns>A EdgeDriverService using a random port.</returns> public static EdgeDriverService CreateDefaultServiceFromOptions(string driverPath, string driverExecutableFileName, EdgeOptions options) { return(CreateDefaultServiceFromOptions(driverPath, driverExecutableFileName, PortUtilities.FindFreePort(), options)); }
/// <summary> /// Creates a default instance of the InternetExplorerDriverService using a specified path to the IEDriverServer executable. /// </summary> /// <param name="driverPath">The directory containing the IEDriverServer executable.</param> /// <returns>A InternetExplorerDriverService using a random port.</returns> public static InternetExplorerDriverService CreateDefaultService(string driverPath) { return(new InternetExplorerDriverService(driverPath, PortUtilities.FindFreePort())); }
/// <summary> /// Creates a default instance of the EdgeDriverService using a specified path to the EdgeDriver executable with the given name. /// </summary> /// <param name="driverPath">The directory containing the EdgeDriver executable.</param> /// <param name="driverExecutableFileName">The name of the EdgeDriver executable file.</param> /// <returns>A EdgeDriverService using a random port.</returns> public static EdgeDriverService CreateDefaultService(string driverPath, string driverExecutableFileName, bool isLegacy = true) { return(CreateDefaultService(driverPath, driverExecutableFileName, PortUtilities.FindFreePort(), isLegacy)); }