File tree Expand file tree Collapse file tree 3 files changed +17
-17
lines changed
dotnet/SeleniumDocs/Drivers
java/src/test/java/dev/selenium/drivers Expand file tree Collapse file tree 3 files changed +17
-17
lines changed Original file line number Diff line number Diff line change @@ -20,14 +20,14 @@ public void BasicService()
20
20
driver = new ChromeDriver ( service ) ;
21
21
}
22
22
23
- [ TestMethod ]
24
- public void DriverLocation ( )
25
- {
26
- var service = ChromeDriverService . CreateDefaultService ( ) ;
27
- service . DriverServicePath = driverLocation ;
28
-
29
- driver = new ChromeDriver ( service ) ;
30
- }
23
+ // [TestMethod]
24
+ // public void DriverLocation()
25
+ // {
26
+ // var service = ChromeDriverService.CreateDefaultService();
27
+ // service.DriverServicePath = driverLocation;
28
+ //
29
+ // driver = new ChromeDriver(service);
30
+ // }
31
31
32
32
[ TestMethod ]
33
33
public void DriverPort ( )
Original file line number Diff line number Diff line change 7
7
import org .openqa .selenium .chrome .ChromeDriver ;
8
8
import org .openqa .selenium .chrome .ChromeDriverService ;
9
9
import org .openqa .selenium .chrome .ChromeOptions ;
10
- import org .openqa .selenium .remote .service .DriverFinder ;
10
+ // import org.openqa.selenium.remote.service.DriverFinder;
11
11
12
12
import java .io .File ;
13
13
14
14
public class ServiceTest extends BaseTest {
15
15
private static File driverLocation ;
16
16
17
- @ BeforeAll
18
- public static void installDriver () {
19
- String location = DriverFinder .getPath (ChromeDriverService .createDefaultService (), new ChromeOptions ());
20
- driverLocation = new File (location );
21
- }
17
+ // @BeforeAll
18
+ // public static void installDriver() {
19
+ // String location = DriverFinder.getPath(ChromeDriverService.createDefaultService(), new ChromeOptions());
20
+ // driverLocation = new File(location);
21
+ // }
22
22
23
23
@ AfterEach
24
24
public void quit () {
Original file line number Diff line number Diff line change 1
1
import logging
2
2
import os
3
+ import sys
3
4
import tempfile
4
5
from datetime import datetime
5
6
@@ -18,9 +19,8 @@ def driver():
18
19
19
20
@pytest .fixture (scope = 'function' )
20
21
def chromedriver_path ():
21
- service = webdriver .chrome .service .Service ()
22
- options = webdriver .ChromeOptions ()
23
- return webdriver .common .driver_finder .DriverFinder ().get_path (service = service , options = options )
22
+ driver = "chromedriver.exe" if sys .platform == "win32" else "chromedriver"
23
+ return os .getenv ("CHROMEWEBDRIVER" ) + driver
24
24
25
25
26
26
@pytest .fixture (scope = 'function' )
You can’t perform that action at this time.
0 commit comments