mirror of https://github.com/apache/archiva.git
fix the search test
git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@899055 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
f6a631b7d5
commit
4457762692
|
@ -25,7 +25,7 @@ public abstract class AbstractSearchTest
|
||||||
//Search
|
//Search
|
||||||
public void goToSearchPage()
|
public void goToSearchPage()
|
||||||
{
|
{
|
||||||
if ( !"Apache Archiva \\ Quick Search".equals( getSelenium().getTitle() ) )
|
if ( !"Apache Archiva \\ Quick Search".equals( getTitle() ) )
|
||||||
{
|
{
|
||||||
clickLinkWithText( "Search" );
|
clickLinkWithText( "Search" );
|
||||||
getSelenium().waitForPageToLoad( maxWaitTimeInMs );
|
getSelenium().waitForPageToLoad( maxWaitTimeInMs );
|
||||||
|
|
|
@ -140,14 +140,13 @@ public abstract class AbstractSeleniumTest {
|
||||||
|
|
||||||
public void assertPage( String title )
|
public void assertPage( String title )
|
||||||
{
|
{
|
||||||
// Collapse spaces
|
Assert.assertEquals( getTitle(), title );
|
||||||
String actualTitle = getSelenium().getTitle().replaceAll( "[ \n\r]+", " " );
|
|
||||||
Assert.assertEquals( actualTitle, title );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getTitle()
|
public String getTitle()
|
||||||
{
|
{
|
||||||
return getSelenium().getTitle();
|
// Collapse spaces
|
||||||
|
return getSelenium().getTitle().replaceAll( "[ \n\r]+", " " );
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getHtmlContent()
|
public String getHtmlContent()
|
||||||
|
|
Loading…
Reference in New Issue