diff options
Diffstat (limited to 'uitest/src/com/vaadin/tests/tb3/AbstractTB3Test.java')
-rw-r--r-- | uitest/src/com/vaadin/tests/tb3/AbstractTB3Test.java | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/uitest/src/com/vaadin/tests/tb3/AbstractTB3Test.java b/uitest/src/com/vaadin/tests/tb3/AbstractTB3Test.java index f6e58a51b2..d7b7cd050f 100644 --- a/uitest/src/com/vaadin/tests/tb3/AbstractTB3Test.java +++ b/uitest/src/com/vaadin/tests/tb3/AbstractTB3Test.java @@ -107,16 +107,19 @@ public abstract class AbstractTB3Test extends TestBenchTestCase { * If something goes wrong */ protected void setupDriver() throws Exception { + DesiredCapabilities capabilities; + RunLocally runLocally = getClass().getAnnotation(RunLocally.class); if (runLocally != null) { - setupLocalDriver(runLocally.value().getDesiredCapabilities()); - return; - } - DesiredCapabilities capabilities = getDesiredCapabilities(); + capabilities = runLocally.value().getDesiredCapabilities(); + setupLocalDriver(capabilities); + } else { + capabilities = getDesiredCapabilities(); - WebDriver dr = TestBench.createDriver(new RemoteWebDriver(new URL( - getHubURL()), capabilities)); - setDriver(dr); + WebDriver dr = TestBench.createDriver(new RemoteWebDriver(new URL( + getHubURL()), capabilities)); + setDriver(dr); + } int w = SCREENSHOT_WIDTH; int h = SCREENSHOT_HEIGHT; |