From: Olivier Lamy Date: Wed, 29 Feb 2012 19:46:04 +0000 (+0000) Subject: fix selenium test due to i18n change X-Git-Tag: archiva-1.4-M3~1172 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=547e68a6e8f84bf762baa61e1adae8a793ddc875;p=archiva.git fix selenium test due to i18n change git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1295238 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/java/org/apache/archiva/configuration/ArchivaConfigurationTest.java b/archiva-modules/archiva-base/archiva-configuration/src/test/java/org/apache/archiva/configuration/ArchivaConfigurationTest.java index 2ecdc0dc6..54bad1b24 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/java/org/apache/archiva/configuration/ArchivaConfigurationTest.java +++ b/archiva-modules/archiva-base/archiva-configuration/src/test/java/org/apache/archiva/configuration/ArchivaConfigurationTest.java @@ -306,8 +306,7 @@ public class ArchivaConfigurationTest userFile.getParentFile( ).mkdirs( ); FileUtils.writeStringToFile( userFile, "", null ); - ArchivaConfiguration archivaConfiguration = - (ArchivaConfiguration) lookup( ArchivaConfiguration.class, "test-save-user" ); + ArchivaConfiguration archivaConfiguration = lookup( ArchivaConfiguration.class, "test-save-user" ); Configuration configuration = new Configuration( ); configuration.setWebapp( new WebappConfiguration( ) ); @@ -336,8 +335,7 @@ public class ArchivaConfigurationTest userFile.delete( ); assertFalse( userFile.exists( ) ); - ArchivaConfiguration archivaConfiguration = - (ArchivaConfiguration) lookup( ArchivaConfiguration.class, "test-save-user-defaults" ); + ArchivaConfiguration archivaConfiguration = lookup( ArchivaConfiguration.class, "test-save-user-defaults" ); archivaConfiguration.reload( ); diff --git a/archiva-modules/archiva-web/archiva-webapp-test-js/src/test/testng/org/apache/archiva/web/test/parent/AbstractArchivaTest.java b/archiva-modules/archiva-web/archiva-webapp-test-js/src/test/testng/org/apache/archiva/web/test/parent/AbstractArchivaTest.java index dd5dab4c3..fa7590025 100644 --- a/archiva-modules/archiva-web/archiva-webapp-test-js/src/test/testng/org/apache/archiva/web/test/parent/AbstractArchivaTest.java +++ b/archiva-modules/archiva-web/archiva-webapp-test-js/src/test/testng/org/apache/archiva/web/test/parent/AbstractArchivaTest.java @@ -235,8 +235,8 @@ public abstract class AbstractArchivaTest clickLinkWithLocator( "user-create-form-register-button", true ); - assertTextPresent( "user created:"+userName ); - assertElementPresent( "users-grid-user-id-"+userName ); + assertTextPresent( "User " + userName + " created." ); + assertElementPresent( "users-grid-user-id-" + userName ); if ( valid ) { @@ -264,12 +264,11 @@ public abstract class AbstractArchivaTest clickLinkWithLocator( "users-grid-delete-" + userName ); clickLinkWithLocator( "dialog-confirm-modal-ok" ); - - assertTextPresent( "user " + userName + " deleted" ); + assertTextPresent( "User " + userName + " deleted." ); clickLinkWithLocator( "alert-message-success-close-a" ); - assertElementNotPresent( "users-grid-user-id-"+userName ); + assertElementNotPresent( "users-grid-user-id-" + userName ); assertTextNotPresent( fullName );