|
17 | 17 |
|
18 | 18 | package org.openqa.selenium.remote.server; |
19 | 19 |
|
20 | | -import static org.junit.Assert.assertTrue; |
21 | | -import static org.openqa.selenium.json.Json.MAP_TYPE; |
22 | | -import static org.openqa.selenium.remote.http.Contents.string; |
23 | | -import static org.openqa.selenium.testing.drivers.Browser.CHROME; |
24 | | -import static org.openqa.selenium.testing.drivers.Browser.EDGE; |
25 | | -import static org.openqa.selenium.testing.drivers.Browser.HTMLUNIT; |
26 | | -import static org.openqa.selenium.testing.drivers.Browser.IE; |
27 | | -import static org.openqa.selenium.testing.drivers.Browser.SAFARI; |
28 | | - |
29 | 20 | import org.junit.After; |
30 | 21 | import org.junit.AfterClass; |
31 | 22 | import org.junit.BeforeClass; |
|
44 | 35 | import org.openqa.selenium.testing.JUnit4TestBase; |
45 | 36 | import org.openqa.selenium.testing.drivers.Browser; |
46 | 37 | import org.openqa.selenium.testing.drivers.OutOfProcessSeleniumServer; |
47 | | -import org.openqa.selenium.testing.drivers.WebDriverBuilder; |
48 | 38 |
|
49 | 39 | import java.io.IOException; |
50 | 40 | import java.net.URL; |
51 | 41 | import java.util.Map; |
| 42 | +import java.util.Objects; |
52 | 43 | import java.util.Set; |
53 | 44 |
|
| 45 | +import static org.junit.Assert.assertTrue; |
| 46 | +import static org.openqa.selenium.json.Json.MAP_TYPE; |
| 47 | +import static org.openqa.selenium.remote.http.Contents.string; |
| 48 | +import static org.openqa.selenium.testing.drivers.Browser.CHROME; |
| 49 | +import static org.openqa.selenium.testing.drivers.Browser.EDGE; |
| 50 | +import static org.openqa.selenium.testing.drivers.Browser.HTMLUNIT; |
| 51 | +import static org.openqa.selenium.testing.drivers.Browser.IE; |
| 52 | +import static org.openqa.selenium.testing.drivers.Browser.SAFARI; |
| 53 | + |
54 | 54 | @Ignore(HTMLUNIT) |
55 | 55 | @Ignore(IE) |
56 | 56 | @Ignore(CHROME) |
@@ -82,7 +82,7 @@ public void stopDriver() { |
82 | 82 | } |
83 | 83 |
|
84 | 84 | private void startDriver() { |
85 | | - Capabilities caps = WebDriverBuilder.getStandardCapabilitiesFor(Browser.detect()); |
| 85 | + Capabilities caps = Objects.requireNonNull(Browser.detect()).getCapabilities(); |
86 | 86 | localDriver = new RemoteWebDriver(server.getWebDriverUrl(), caps); |
87 | 87 | localDriver.setFileDetector(new LocalFileDetector()); |
88 | 88 | } |
|
0 commit comments