Exemple #1
0
        /// <summary>
        /// Creates a default instance of the EdgeDriverService.
        /// </summary>
        /// <returns>A EdgeDriverService that implements default settings.</returns>
        public static EdgeDriverService CreateDefaultService()
        {
            string            serviceDirectory = DriverService.FindDriverServiceExecutable(MicrosoftWebDriverServiceFileName, MicrosoftWebDriverDownloadUrl);
            EdgeDriverService service          = CreateDefaultService(serviceDirectory);

            return(service);
        }
Exemple #2
0
        private static EdgeDriverService CreateSpecCompliantEdgeDriverService()
        {
            EdgeDriverService service = EdgeDriverService.CreateDefaultService();

            service.UseSpecCompliantProtocol = true;
            return(service);
        }
Exemple #3
0
        /// <summary>
        /// Creates a default instance of the EdgeDriverService.
        /// </summary>
        /// <param name="isLegacy">Wheter to use legacy mode. Default is to true.</param>
        /// <returns>A EdgeDriverService that implements default settings.</returns>
        public static EdgeDriverService CreateDefaultService(bool isLegacy = true, NetworkCredential user = null)
        {
            string serviceFileName = ChromiumDriverServiceFileName(MSEdgeDriverServiceFileName);

            if (isLegacy)
            {
                serviceFileName = MicrosoftWebDriverServiceFileName;
            }

            string            serviceDirectory = DriverService.FindDriverServiceExecutable(serviceFileName, MicrosoftWebDriverDownloadUrl);
            EdgeDriverService service          = CreateDefaultService(serviceDirectory, isLegacy, user);

            return(service);
        }
 public DefaultEdgeDriver(EdgeDriverService service, EdgeOptions options)
     : base(service, options)
 {
 }
Exemple #5
0
 /// <summary>
 /// Initializes a new instance of the <see cref="EdgeDriver"/> class using the specified
 /// <see cref="EdgeDriverService"/> and options.
 /// </summary>
 /// <param name="service">The <see cref="EdgeDriverService"/> to use.</param>
 /// <param name="options">The <see cref="EdgeOptions"/> used to initialize the driver.</param>
 public EdgeDriver(EdgeDriverService service, EdgeOptions options)
     : this(service, options, RemoteWebDriver.DefaultCommandTimeout)
 {
 }
Exemple #6
0
 /// <summary>
 /// Initializes a new instance of the <see cref="EdgeDriver"/> class using the specified
 /// <see cref="EdgeDriverService"/> and options.
 /// </summary>
 /// <param name="service">The <see cref="EdgeDriverService"/> to use.</param>
 /// <param name="options">The <see cref="EdgeOptions"/> used to initialize the driver.</param>
 public EdgeDriver(EdgeDriverService service, EdgeOptions options)
     : this(service, options, RemoteWebDriver.DefaultCommandTimeout)
 {
 }
Exemple #7
0
 /// <summary>
 /// Initializes a new instance of the <see cref="EdgeDriver"/> class using the specified driver service.
 /// </summary>
 /// <param name="service">The <see cref="EdgeDriverService"/> used to initialize the driver.</param>
 public EdgeDriver(EdgeDriverService service)
     : this(service, new EdgeOptions())
 {
 }
Exemple #8
0
 /// <summary>
 /// Initializes a new instance of the <see cref="EdgeDriver"/> class using the specified <see cref="EdgeDriverService"/>.
 /// </summary>
 /// <param name="service">The <see cref="EdgeDriverService"/> to use.</param>
 /// <param name="options">The <see cref="EdgeOptions"/> to be used with the Edge driver.</param>
 /// <param name="commandTimeout">The maximum amount of time to wait for each command.</param>
 public EdgeDriver(EdgeDriverService service, EdgeOptions options, TimeSpan commandTimeout)
     : base(service, options, commandTimeout)
 {
 }
Exemple #9
0
 public EdgeDriver(EdgeDriverService service, EdgeOptions options, TimeSpan commandTimeout) : base(new DriverServiceCommandExecutor(service, commandTimeout), EdgeDriver.ConvertOptionsToCapabilities(options))
 {
 }
Exemple #10
0
 public ChromiumEdgeDriver(EdgeDriverService service, EdgeOptions options)
     : base(service, options)
 {
 }
Exemple #11
0
 /// <summary>
 /// Initializes a new instance of the <see cref="EdgeDriver"/> class using the specified <see cref="EdgeDriverService"/>.
 /// </summary>
 /// <param name="service">The <see cref="EdgeDriverService"/> to use.</param>
 /// <param name="options">The <see cref="EdgeOptions"/> to be used with the Edge driver.</param>
 /// <param name="commandTimeout">The maximum amount of time to wait for each command.</param>
 public EdgeDriver(EdgeDriverService service, EdgeOptions options, TimeSpan commandTimeout)
     : base(new DriverServiceCommandExecutor(service, commandTimeout), ConvertOptionsToCapabilities(options))
 {
     System.Threading.Thread.Sleep(1000);
 }
Exemple #12
0
 /// <summary>
 /// Initializes a new instance of the <see cref="EdgeDriver"/> class using the specified <see cref="EdgeDriverService"/>.
 /// </summary>
 /// <param name="service">The <see cref="EdgeDriverService"/> to use.</param>
 /// <param name="options">The <see cref="EdgeOptions"/> to be used with the Edge driver.</param>
 /// <param name="commandTimeout">The maximum amount of time to wait for each command.</param>
 public EdgeDriver(EdgeDriverService service, EdgeOptions options, TimeSpan commandTimeout)
     : base(service, options, commandTimeout)
 {
     this.AddCustomEdgeCommands();
 }
 public static EdgeDriverService CreateDefaultService(string driverPath, string driverExecutableFileName)
 {
     return(EdgeDriverService.CreateDefaultService(driverPath, driverExecutableFileName, PortUtilities.FindFreePort()));
 }
 public static EdgeDriverService CreateDefaultService(string driverPath)
 {
     return(EdgeDriverService.CreateDefaultService(driverPath, "MicrosoftWebDriver.exe"));
 }
        public static EdgeDriverService CreateDefaultService()
        {
            string driverPath = DriverService.FindDriverServiceExecutable("MicrosoftWebDriver.exe", EdgeDriverService.MicrosoftWebDriverDownloadUrl);

            return(EdgeDriverService.CreateDefaultService(driverPath));
        }
Exemple #16
0
 public EdgeDriver(EdgeOptions options) : this(EdgeDriverService.CreateDefaultService(), options, RemoteWebDriver.DefaultCommandTimeout)
 {
 }
Exemple #17
0
 /// <summary>
 /// Initializes a new instance of the <see cref="EdgeDriver"/> class using the specified driver service.
 /// </summary>
 /// <param name="service">The <see cref="EdgeDriverService"/> used to initialize the driver.</param>
 public EdgeDriver(EdgeDriverService service)
     : this(service, new EdgeOptions() { UseChromium = service.UsingChromium })
 {
 }
 public SpecCompliantEdgeDriver(EdgeDriverService service, EdgeOptions options)
     : base(service, options)
 {
 }
Exemple #19
0
 public DevChannelEdgeDriver(EdgeDriverService service, EdgeOptions options)
     : base(service, options)
 {
 }
Exemple #20
0
 /// <summary>
 /// Initializes a new instance of the <see cref="EdgeDriver"/> class using the specified options.
 /// </summary>
 /// <param name="options">The <see cref="EdgeOptions"/> to be used with the Edge driver.</param>
 public EdgeDriver(EdgeOptions options)
     : this(EdgeDriverService.CreateDefaultService(), options)
 {
 }
Exemple #21
0
 public LegacyEdgeDriver(EdgeDriverService service, EdgeOptions options)
     : base(service, options)
 {
 }
Exemple #22
0
 /// <summary>
 /// Initializes a new instance of the <see cref="EdgeDriver"/> class using the specified path
 /// to the directory containing EdgeDriver.exe, options, and command timeout.
 /// </summary>
 /// <param name="edgeDriverDirectory">The full path to the directory containing EdgeDriver.exe.</param>
 /// <param name="options">The <see cref="EdgeOptions"/> to be used with the Edge driver.</param>
 /// <param name="commandTimeout">The maximum amount of time to wait for each command.</param>
 public EdgeDriver(string edgeDriverDirectory, EdgeOptions options, TimeSpan commandTimeout)
     : this(EdgeDriverService.CreateDefaultService(edgeDriverDirectory), options, commandTimeout)
 {
 }
Exemple #23
0
 /// <summary>
 /// Initializes a new instance of the <see cref="EdgeDriver"/> class using the specified <see cref="EdgeDriverService"/>.
 /// </summary>
 /// <param name="service">The <see cref="EdgeDriverService"/> to use.</param>
 /// <param name="options">The <see cref="EdgeOptions"/> to be used with the Edge driver.</param>
 /// <param name="commandTimeout">The maximum amount of time to wait for each command.</param>
 public EdgeDriver(EdgeDriverService service, EdgeOptions options, TimeSpan commandTimeout)
     : base(new DriverServiceCommandExecutor(service, commandTimeout), ConvertOptionsToCapabilities(options))
 {
 }
Exemple #24
0
 /// <summary>
 /// Initializes a new instance of the <see cref="EdgeDriver"/> class using the specified driver service.
 /// </summary>
 /// <param name="service">The <see cref="EdgeDriverService"/> used to initialize the driver.</param>
 public EdgeDriver(EdgeDriverService service)
     : this(service, new EdgeOptions())
 {
 }
Exemple #25
0
 /// <summary>
 /// Initializes a new instance of the <see cref="EdgeDriver"/> class using the specified <see cref="EdgeDriverService"/>.
 /// </summary>
 /// <param name="service">The <see cref="EdgeDriverService"/> to use.</param>
 /// <param name="options">The <see cref="EdgeOptions"/> to be used with the Edge driver.</param>
 /// <param name="commandTimeout">The maximum amount of time to wait for each command.</param>
 public EdgeDriver(EdgeDriverService service, EdgeOptions options, TimeSpan commandTimeout)
     : base(new DriverServiceCommandExecutor(service, commandTimeout), ConvertOptionsToCapabilities(options))
 {
     System.Threading.Thread.Sleep(1000);
 }