Provides a mechanism to Add the WebDriver Extension
示例#1
0
 /// <summary>
 /// Initializes a new instance of the ChromeBinary class using the given <see cref="ChromeProfile"/>, <see cref="ChromeExtension"/> and port value.
 /// </summary>
 /// <param name="profile">The Chrome profile to use.</param>
 /// <param name="extension">The extension to launch Chrome with.</param>
 /// <param name="port">The port on which to listen for commands.</param>
 internal ChromeBinary(ChromeProfile profile, ChromeExtension extension, int port)
 {
     this.profile   = profile;
     this.extension = extension;
     if (port == 0)
     {
         this.FindFreePort();
     }
     else
     {
         this.listeningPort = port;
     }
 }
示例#2
0
 /// <summary>
 /// Initializes a new instance of the ChromeBinary class using the given <see cref="ChromeProfile"/>, <see cref="ChromeExtension"/> and port value.
 /// </summary>
 /// <param name="profile">The Chrome profile to use.</param>
 /// <param name="extension">The extension to launch Chrome with.</param>
 /// <param name="port">The port on which to listen for commands.</param>
 internal ChromeBinary(ChromeProfile profile, ChromeExtension extension, int port)
 {
     this.profile = profile;
     this.extension = extension;
     if (port == 0)
     {
         this.FindFreePort();
     }
     else
     {
         this.listeningPort = port;
     }
 }
示例#3
0
 /// <summary>
 /// Initializes a new instance of the ChromeDriver class using the specified profile and extension.
 /// </summary>
 /// <param name="profile">The profile to use.</param>
 /// <param name="extension">The extension to use.</param>
 private ChromeDriver(ChromeProfile profile, ChromeExtension extension)
     : base(new ChromeCommandExecutor(new ChromeBinary(profile, extension)), DesiredCapabilities.Chrome())
 {
 }
示例#4
0
 /// <summary>
 /// Initializes a new instance of the ChromeDriver class using the specified profile and extension.
 /// </summary>
 /// <param name="profile">The profile to use.</param>
 /// <param name="extension">The extension to use.</param>
 private ChromeDriver(ChromeProfile profile, ChromeExtension extension)
     : base(new ChromeCommandExecutor(new ChromeBinary(profile, extension)), DesiredCapabilities.Chrome())
 {
 }
示例#5
0
 /// <summary>
 /// Initializes a new instance of the ChromeBinary class using the given <see cref="ChromeProfile"/> and <see cref="ChromeExtension"/>.
 /// </summary>
 /// <param name="profile">The Chrome profile to use.</param>
 /// <param name="extension">The extension to launch Chrome with.</param>
 internal ChromeBinary(ChromeProfile profile, ChromeExtension extension)
     : this(profile, extension, 0)
 {
 }
示例#6
0
 /// <summary>
 /// Initializes a new instance of the ChromeBinary class using the given <see cref="ChromeProfile"/> and <see cref="extension"/>.
 /// </summary>
 /// <param name="profile">The Chrome profile to use.</param>
 /// <param name="extension">The extension to launch Chrome with.</param>
 internal ChromeBinary(ChromeProfile profile, ChromeExtension extension)
 {
     this.profile = profile;
     this.extension = extension;
 }
示例#7
0
 /// <summary>
 /// Initializes a new instance of the ChromeDriver class using the specified profile and extension.
 /// </summary>
 /// <param name="profile">The profile to use.</param>
 /// <param name="extension">The extension to use.</param>
 private ChromeDriver(ChromeProfile profile, ChromeExtension extension)
 {
     chromeBinary = new ChromeBinary(profile, extension);
     executor = new ChromeCommandExecutor();
     StartClient();
 }
示例#8
0
 /// <summary>
 /// Initializes a new instance of the ChromeBinary class using the given <see cref="ChromeProfile"/> and <see cref="ChromeExtension"/>.
 /// </summary>
 /// <param name="profile">The Chrome profile to use.</param>
 /// <param name="extension">The extension to launch Chrome with.</param>
 internal ChromeBinary(ChromeProfile profile, ChromeExtension extension)
     : this(profile, extension, 0)
 {
 }