diff --git a/archiva-modules/archiva-web/archiva-webapp-test/src/test/testng/org/apache/archiva/web/test/parent/AbstractSeleniumTest.java b/archiva-modules/archiva-web/archiva-webapp-test/src/test/testng/org/apache/archiva/web/test/parent/AbstractSeleniumTest.java index 82531a13a..2e79ad91b 100644 --- a/archiva-modules/archiva-web/archiva-webapp-test/src/test/testng/org/apache/archiva/web/test/parent/AbstractSeleniumTest.java +++ b/archiva-modules/archiva-web/archiva-webapp-test/src/test/testng/org/apache/archiva/web/test/parent/AbstractSeleniumTest.java @@ -26,6 +26,8 @@ import java.util.Map; import java.util.Properties; import java.util.Map.Entry; +import org.codehaus.plexus.util.StringUtils; + import org.testng.Assert; import com.thoughtworks.selenium.DefaultSelenium; import com.thoughtworks.selenium.Selenium; @@ -56,7 +58,13 @@ public abstract class AbstractSeleniumTest { String seleniumHost = p.getProperty( "SELENIUM_HOST" ); int seleniumPort = Integer.parseInt( ( p.getProperty( "SELENIUM_PORT" ) ) ); - String seleniumBrowser = p.getProperty( "SELENIUM_BROWSER" ); + + String seleniumBrowser = System.getProperty( "browser" ); + if ( StringUtils.isEmpty( seleniumBrowser ) ) + { + seleniumBrowser = p.getProperty( "SELENIUM_BROWSER" ); + } + final Selenium s = new DefaultSelenium( seleniumHost, seleniumPort, seleniumBrowser, baseUrl ); selenium = new ThreadLocal() { diff --git a/archiva-modules/archiva-web/archiva-webapp-test/testng-pom.xml b/archiva-modules/archiva-web/archiva-webapp-test/testng-pom.xml index 645d9e5cc..faa2847b6 100644 --- a/archiva-modules/archiva-web/archiva-webapp-test/testng-pom.xml +++ b/archiva-modules/archiva-web/archiva-webapp-test/testng-pom.xml @@ -172,6 +172,14 @@ test + + + + browser + ${selenium.browser} + + + @@ -364,22 +372,48 @@ firefox - true + + !browser + - *firefox + *firefox iexplore + + + browser + iexplore + + - *iexplore + *iexplore + + + + safari + + + browser + safari + + + + *safari otherbrowser + + + browser + other + + - *custom ${browserPath} + *custom ${browserPath}