File tree Expand file tree Collapse file tree 5 files changed +8
-29
lines changed
src/test/java/uk/co/evoco/webdriver/configuration/driver Expand file tree Collapse file tree 5 files changed +8
-29
lines changed Original file line number Diff line number Diff line change 44import org .junit .jupiter .api .Test ;
55import org .openqa .selenium .WebDriver ;
66import org .openqa .selenium .support .events .EventFiringWebDriver ;
7- import uk .co .evoco .webdriver .configuration .WebDriverConfig ;
8- import uk .co .evoco .webdriver .utils .JsonUtils ;
97
108import java .io .IOException ;
119
@@ -16,8 +14,7 @@ public class ConfiguredChromeDriverIT {
1614
1715 @ Test
1816 public void testReturnsLocalWebDriver () throws IOException {
19- WebDriverConfig webDriverConfig = JsonUtils .fromFile (ClassLoader .getSystemResourceAsStream ("fixtures/sample-config.json" ), WebDriverConfig .class );
20- ConfiguredChromeDriver configuredChromeDriver = new ConfiguredChromeDriver (webDriverConfig );
17+ ConfiguredChromeDriver configuredChromeDriver = new ConfiguredChromeDriver ();
2118 WebDriver webDriver = configuredChromeDriver .getDriver (FileUtils .getTempDirectory ());
2219 assertThat (webDriver , instanceOf (EventFiringWebDriver .class ));
2320 }
Original file line number Diff line number Diff line change 66import org .openqa .selenium .support .events .EventFiringWebDriver ;
77import org .slf4j .Logger ;
88import org .slf4j .LoggerFactory ;
9- import uk .co .evoco .webdriver .configuration .WebDriverConfig ;
10- import uk .co .evoco .webdriver .utils .JsonUtils ;
11-
12- import java .io .IOException ;
139
1410import static org .hamcrest .CoreMatchers .instanceOf ;
1511import static org .hamcrest .MatcherAssert .assertThat ;
@@ -19,10 +15,9 @@ public class ConfiguredEdgeDriverIT {
1915 private static final Logger logger = LoggerFactory .getLogger (ConfiguredEdgeDriverIT .class );
2016
2117 @ Test
22- public void testReturnsLocalWebDriver () throws IOException {
18+ public void testReturnsLocalWebDriver () {
2319 if (System .getProperty ("os.name" ).contains ("win" )) {
24- WebDriverConfig webDriverConfig = JsonUtils .fromFile (ClassLoader .getSystemResourceAsStream ("fixtures/sample-config.json" ), WebDriverConfig .class );
25- ConfiguredEdgeDriver configuredEdgeDriver = new ConfiguredEdgeDriver (webDriverConfig );
20+ ConfiguredEdgeDriver configuredEdgeDriver = new ConfiguredEdgeDriver ();
2621 WebDriver webDriver = configuredEdgeDriver .getDriver (FileUtils .getTempDirectory ());
2722 assertThat (webDriver , instanceOf (EventFiringWebDriver .class ));
2823 webDriver .quit ();
Original file line number Diff line number Diff line change 44import org .junit .jupiter .api .Test ;
55import org .openqa .selenium .WebDriver ;
66import org .openqa .selenium .support .events .EventFiringWebDriver ;
7- import uk .co .evoco .webdriver .configuration .WebDriverConfig ;
8- import uk .co .evoco .webdriver .utils .JsonUtils ;
97
108import java .io .IOException ;
119
@@ -16,8 +14,7 @@ public class ConfiguredFirefoxDriverIT {
1614
1715 @ Test
1816 public void testReturnsLocalWebDriver () throws IOException {
19- WebDriverConfig webDriverConfig = JsonUtils .fromFile (ClassLoader .getSystemResourceAsStream ("fixtures/sample-config.json" ), WebDriverConfig .class );
20- ConfiguredFirefoxDriver configuredFirefoxDriver = new ConfiguredFirefoxDriver (webDriverConfig );
17+ ConfiguredFirefoxDriver configuredFirefoxDriver = new ConfiguredFirefoxDriver ();
2118 WebDriver webDriver = configuredFirefoxDriver .getDriver (FileUtils .getTempDirectory ());
2219 assertThat (webDriver , instanceOf (EventFiringWebDriver .class ));
2320 }
Original file line number Diff line number Diff line change 66import org .openqa .selenium .support .events .EventFiringWebDriver ;
77import org .slf4j .Logger ;
88import org .slf4j .LoggerFactory ;
9- import uk .co .evoco .webdriver .configuration .WebDriverConfig ;
10- import uk .co .evoco .webdriver .utils .JsonUtils ;
11-
12- import java .io .IOException ;
139
1410import static org .hamcrest .CoreMatchers .instanceOf ;
1511import static org .hamcrest .MatcherAssert .assertThat ;
@@ -19,10 +15,9 @@ public class ConfiguredInternetExplorerDriverIT {
1915 private static final Logger logger = LoggerFactory .getLogger (ConfiguredInternetExplorerDriverIT .class );
2016
2117 @ Test
22- public void testReturnsLocalWebDriver () throws IOException {
18+ public void testReturnsLocalWebDriver () {
2319 if (System .getProperty ("os.name" ).contains ("win" )) {
24- WebDriverConfig webDriverConfig = JsonUtils .fromFile (ClassLoader .getSystemResourceAsStream ("fixtures/sample-config.json" ), WebDriverConfig .class );
25- ConfiguredInternetExplorerDriver configuredIeDriver = new ConfiguredInternetExplorerDriver (webDriverConfig );
20+ ConfiguredInternetExplorerDriver configuredIeDriver = new ConfiguredInternetExplorerDriver ();
2621 WebDriver webDriver = configuredIeDriver .getDriver (FileUtils .getTempDirectory ());
2722 assertThat (webDriver , instanceOf (EventFiringWebDriver .class ));
2823 webDriver .quit ();
Original file line number Diff line number Diff line change 66import org .openqa .selenium .support .events .EventFiringWebDriver ;
77import org .slf4j .Logger ;
88import org .slf4j .LoggerFactory ;
9- import uk .co .evoco .webdriver .configuration .WebDriverConfig ;
10- import uk .co .evoco .webdriver .utils .JsonUtils ;
11-
12- import java .io .IOException ;
139
1410import static org .hamcrest .CoreMatchers .instanceOf ;
1511import static org .hamcrest .MatcherAssert .assertThat ;
@@ -19,10 +15,9 @@ public class ConfiguredSafariDriverIT {
1915 private static final Logger logger = LoggerFactory .getLogger (ConfiguredSafariDriverIT .class );
2016
2117 @ Test
22- public void testReturnsLocalWebDriver () throws IOException {
18+ public void testReturnsLocalWebDriver () {
2319 if (System .getProperty ("os.name" ).contains ("mac" )) {
24- WebDriverConfig webDriverConfig = JsonUtils .fromFile (ClassLoader .getSystemResourceAsStream ("fixtures/sample-config.json" ), WebDriverConfig .class );
25- ConfiguredSafariDriver configuredSafariDriver = new ConfiguredSafariDriver (webDriverConfig );
20+ ConfiguredSafariDriver configuredSafariDriver = new ConfiguredSafariDriver ();
2621 WebDriver webDriver = configuredSafariDriver .getDriver (FileUtils .getTempDirectory ());
2722 assertThat (webDriver , instanceOf (EventFiringWebDriver .class ));
2823 webDriver .quit ();
You can’t perform that action at this time.
0 commit comments