geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a..@apache.org
Subject svn commit: rev 51820 - geronimo/trunk/modules/jetty/src/test/org/apache/geronimo/jetty
Date Sun, 03 Oct 2004 03:47:46 GMT
Author: adc
Date: Sat Oct  2 20:47:45 2004
New Revision: 51820

Modified:
   geronimo/trunk/modules/jetty/src/test/org/apache/geronimo/jetty/SecurityTest.java
Log:
Updated test to account for http://issues.apache.org/jira/browse/GERONIMO-323

Modified: geronimo/trunk/modules/jetty/src/test/org/apache/geronimo/jetty/SecurityTest.java
==============================================================================
--- geronimo/trunk/modules/jetty/src/test/org/apache/geronimo/jetty/SecurityTest.java	(original)
+++ geronimo/trunk/modules/jetty/src/test/org/apache/geronimo/jetty/SecurityTest.java	Sat
Oct  2 20:47:45 2004
@@ -125,9 +125,13 @@
         assertEquals(HttpURLConnection.HTTP_MOVED_TEMP, connection.getResponseCode());
 
         String cookie = connection.getHeaderField("Set-Cookie");
+        cookie = cookie.substring(0, cookie.lastIndexOf(';'));
         String location = connection.getHeaderField("Location");
 
-        cookie = cookie.substring(0, cookie.lastIndexOf(';'));
+        connection = (HttpURLConnection) new URL(location).openConnection();
+        connection.setInstanceFollowRedirects(false);
+        assertEquals(HttpURLConnection.HTTP_OK, connection.getResponseCode());
+
         location = location.substring(0, location.lastIndexOf('/')) + "/j_security_check?j_username=alan&j_password=starcraft";
 
         connection = (HttpURLConnection) new URL(location).openConnection();

Mime
View raw message