geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From xiam...@apache.org
Subject svn commit: r950659 - in /geronimo/server/branches/2.2/testsuite/security-testsuite/test-security/src/test/java/org/apache/geronimo/testsuite/security: TestConsoleSecurity.java TestSecurity.java
Date Wed, 02 Jun 2010 16:52:12 GMT
Author: xiaming
Date: Wed Jun  2 16:52:12 2010
New Revision: 950659

URL: http://svn.apache.org/viewvc?rev=950659&view=rev
Log:
GERONIMO-5329 Additional updates to fix selenium related failures

Modified:
    geronimo/server/branches/2.2/testsuite/security-testsuite/test-security/src/test/java/org/apache/geronimo/testsuite/security/TestConsoleSecurity.java
    geronimo/server/branches/2.2/testsuite/security-testsuite/test-security/src/test/java/org/apache/geronimo/testsuite/security/TestSecurity.java

Modified: geronimo/server/branches/2.2/testsuite/security-testsuite/test-security/src/test/java/org/apache/geronimo/testsuite/security/TestConsoleSecurity.java
URL: http://svn.apache.org/viewvc/geronimo/server/branches/2.2/testsuite/security-testsuite/test-security/src/test/java/org/apache/geronimo/testsuite/security/TestConsoleSecurity.java?rev=950659&r1=950658&r2=950659&view=diff
==============================================================================
--- geronimo/server/branches/2.2/testsuite/security-testsuite/test-security/src/test/java/org/apache/geronimo/testsuite/security/TestConsoleSecurity.java
(original)
+++ geronimo/server/branches/2.2/testsuite/security-testsuite/test-security/src/test/java/org/apache/geronimo/testsuite/security/TestConsoleSecurity.java
Wed Jun  2 16:52:12 2010
@@ -30,11 +30,11 @@ public class TestConsoleSecurity extends
         selenium.open("/console");
         waitForPageLoad();
         assertFalse(selenium.isTextPresent("Deploy New"));
-        selenium.type("j_username", "system");
-        selenium.type("j_password", "manager");
+        selenium.type("//input[@name='j_username']", "system");
+        selenium.type("//input[@name='j_password']", "manager");
         selenium.click("submit");
         waitForPageLoad();
-        assertTrue(selenium.isTextPresent("Deploy New"));
+        assertEquals("Geronimo Console", selenium.getTitle());
         selenium.click("//a[contains(@href, '/console/logout.jsp')]");
         waitForPageLoad();
         assertEquals("Geronimo Console Login", selenium.getTitle());
@@ -74,10 +74,12 @@ public class TestConsoleSecurity extends
         selenium.open("/console");
         waitForPageLoad();
         if (username != null) {
-            selenium.type("j_username", username);
+            //selenium.type("j_username", username);
+            selenium.type("//input[@name='j_username']", username);
         }
         if (password != null) {
-            selenium.type("j_password", password);
+            //selenium.type("j_password", password);
+            selenium.type("//input[@name='j_password']", password);
         }
         selenium.click("submit");
         waitForPageLoad();

Modified: geronimo/server/branches/2.2/testsuite/security-testsuite/test-security/src/test/java/org/apache/geronimo/testsuite/security/TestSecurity.java
URL: http://svn.apache.org/viewvc/geronimo/server/branches/2.2/testsuite/security-testsuite/test-security/src/test/java/org/apache/geronimo/testsuite/security/TestSecurity.java?rev=950659&r1=950658&r2=950659&view=diff
==============================================================================
--- geronimo/server/branches/2.2/testsuite/security-testsuite/test-security/src/test/java/org/apache/geronimo/testsuite/security/TestSecurity.java
(original)
+++ geronimo/server/branches/2.2/testsuite/security-testsuite/test-security/src/test/java/org/apache/geronimo/testsuite/security/TestSecurity.java
Wed Jun  2 16:52:12 2010
@@ -32,6 +32,7 @@ public class TestSecurity extends Seleni
         selenium.type("j_password", "bone");
         selenium.click("submit");
         waitForPageLoad();
+        selenium.open("/demo/protect/hello.html");
         assertEquals("hello world.", selenium.getText("xpath=/html"));
         selenium.deleteAllVisibleCookies();
     }



Mime
View raw message