diff options
-rw-r--r-- | uitest/src/com/vaadin/tests/tb3/PrivateTB3Configuration.java | 19 |
1 files changed, 4 insertions, 15 deletions
diff --git a/uitest/src/com/vaadin/tests/tb3/PrivateTB3Configuration.java b/uitest/src/com/vaadin/tests/tb3/PrivateTB3Configuration.java index dce725b7c0..61b7ef4dde 100644 --- a/uitest/src/com/vaadin/tests/tb3/PrivateTB3Configuration.java +++ b/uitest/src/com/vaadin/tests/tb3/PrivateTB3Configuration.java @@ -93,16 +93,15 @@ public abstract class PrivateTB3Configuration extends ScreenshotTB3Test { } private static DesiredCapabilities getRunLocallyCapabilities() { - Browser localBrowser; + VaadinBrowserFactory factory = new VaadinBrowserFactory(); try { - localBrowser = Browser.valueOf(properties.getProperty( - RUN_LOCALLY_PROPERTY).toUpperCase()); + return factory.create(Browser.valueOf(properties.getProperty( + RUN_LOCALLY_PROPERTY).toUpperCase())); } catch (Exception e) { System.err.println(e.getMessage()); System.err.println("Falling back to FireFox"); - localBrowser = Browser.FIREFOX; } - return localBrowser.getDesiredCapabilities(); + return factory.create(Browser.FIREFOX); } protected static String getProperty(String name) { @@ -114,16 +113,6 @@ public abstract class PrivateTB3Configuration extends ScreenshotTB3Test { return property; } - private static String getSource(String propertyName) { - if (properties.containsKey(propertyName)) { - return propertiesFile.getAbsolutePath(); - } else if (System.getProperty(propertyName) != null) { - return "System.getProperty()"; - } else { - return null; - } - } - @Override protected String getScreenshotDirectory() { String screenshotDirectory = getProperty(SCREENSHOT_DIRECTORY); |