diff options
author | Brett Porter <brett@apache.org> | 2009-11-10 10:12:04 +0000 |
---|---|---|
committer | Brett Porter <brett@apache.org> | 2009-11-10 10:12:04 +0000 |
commit | d6e13a5e3b7d9283e8a42cdff9289ac35da61358 (patch) | |
tree | 1b44b95c1b0db6dbd76514a4c99d10a6ca4f3ce8 | |
parent | 737ef895801965e29e5caa7f1bb20585d6242433 (diff) | |
download | archiva-d6e13a5e3b7d9283e8a42cdff9289ac35da61358.tar.gz archiva-d6e13a5e3b7d9283e8a42cdff9289ac35da61358.zip |
make test more resilient to whitespace in titles
git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@834410 13f79535-47bb-0310-9956-ffa450edef68
-rw-r--r-- | archiva-modules/archiva-web/archiva-webapp-test/src/test/testng/org/apache/archiva/web/test/parent/AbstractSeleniumTest.java | 12 |
1 files changed, 6 insertions, 6 deletions
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 938ab1d97..7fb7701b0 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 @@ -60,8 +60,6 @@ public abstract class AbstractSeleniumTest { //baseUrl = getProperty( "BASE_URL" ); maxWaitTimeInMs = getProperty( "MAX_WAIT_TIME_IN_MS" ); - - } /** @@ -139,10 +137,12 @@ public abstract class AbstractSeleniumTest { Assert.assertEquals( fieldValue, getSelenium().getValue( fieldName ) ); } - public void assertPage( String title ) - { - Assert.assertEquals( getSelenium().getTitle(), title ); - } + public void assertPage( String title ) + { + // Collapse spaces + String actualTitle = getSelenium().getTitle().replaceAll( "[ \n\r]+", " " ); + Assert.assertEquals( actualTitle, title ); + } public String getTitle() { |