]> source.dussan.org Git - archiva.git/commitdiff
test login and register links are not here where creating admin is needed
authorOlivier Lamy <olamy@apache.org>
Mon, 23 Jan 2012 08:33:25 +0000 (08:33 +0000)
committerOlivier Lamy <olamy@apache.org>
Mon, 23 Jan 2012 08:33:25 +0000 (08:33 +0000)
git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1234697 13f79535-47bb-0310-9956-ffa450edef68

archiva-modules/archiva-web/archiva-webapp-test-js/src/test/testng/org/apache/archiva/web/test/ArchivaAdminTest.java

index 84bdfef1be6971431b94ce0f5943ef3ead08ff5c..49387032f0d55b290b3b433a7460a043c680b85f 100644 (file)
@@ -20,6 +20,7 @@ package org.apache.archiva.web.test;
  */
 
 import org.apache.archiva.web.test.parent.AbstractArchivaTest;
+import org.testng.Assert;
 import org.testng.annotations.AfterTest;
 import org.testng.annotations.BeforeSuite;
 import org.testng.annotations.BeforeTest;
@@ -63,6 +64,8 @@ public class ArchivaAdminTest
         // if not admin user created create one
         if ( isElementVisible( "create-admin-link" ) )
         {
+            Assert.assertFalse( getSelenium().isVisible( "login-link-a" ) );
+            Assert.assertFalse( getSelenium().isVisible( "register-link-a" ) );
             clickLinkWithLocator( "create-admin-link-a", false );
             assertCreateAdmin();
             String fullname = getProperty( "ADMIN_FULLNAME" );
@@ -75,6 +78,8 @@ public class ArchivaAdminTest
         }
         else
         {
+            Assert.assertTrue( getSelenium().isVisible( "login-link-a" ) );
+            Assert.assertTrue( getSelenium().isVisible( "register-link-a" ) );
             login( getAdminUsername(), getAdminPassword() );
         }