User: starksm 
  Date: 01/10/19 17:57:35

  Modified:    src/main/org/jboss/test/web/test Tag: Branch_2_4
                        TestWebIntegration.java
  Log:
  Add tests of multiple secured URIs
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.7.2.6   +27 -6     
jbosstest/src/main/org/jboss/test/web/test/Attic/TestWebIntegration.java
  
  Index: TestWebIntegration.java
  ===================================================================
  RCS file: 
/cvsroot/jboss/jbosstest/src/main/org/jboss/test/web/test/Attic/TestWebIntegration.java,v
  retrieving revision 1.7.2.5
  retrieving revision 1.7.2.6
  diff -u -r1.7.2.5 -r1.7.2.6
  --- TestWebIntegration.java   2001/10/05 07:23:05     1.7.2.5
  +++ TestWebIntegration.java   2001/10/20 00:57:34     1.7.2.6
  @@ -26,7 +26,7 @@
    with a role of 'AuthorizedUser' in the servlet container.
    
    @author [EMAIL PROTECTED]
  - @version $Revision: 1.7.2.5 $
  + @version $Revision: 1.7.2.6 $
    */
   public class TestWebIntegration extends TestCase
   {
  @@ -81,11 +81,10 @@
               }
               // Flush the security domain cache to avoid conflicts with other 
testcases
               ObjectName jaasMgr = new 
ObjectName("Security:name=JaasSecurityManager");
  -            params = new Object[]
  -            {"other"};
  -            signature = new String[]
  -            {"java.lang.String"};
  +            params = new Object[] {"other"};
  +            signature = new String[] {"java.lang.String"};
               server.invoke(jaasMgr, "flushAuthenticationCache", params, signature);
  +            System.out.println("Invokded flushAuthenticationCache(other)");
            }
            else
            {
  @@ -162,7 +161,12 @@
            return;
         
         URL url = new URL(baseURL+"jbosstest/restricted/SecureServlet");
  -      accessURL(url);
  +      System.out.println("Try #1");
  +      accessURL(url, true);
  +      System.out.println("Try #2");
  +      accessURL(url, true);
  +      System.out.println("Try #3");
  +      accessURL(url, true);
      }
      /** Access the http://localhost/jbosstest/restricted/SecureServlet
       */
  @@ -215,6 +219,23 @@
            return;
         
         URL url = new URL(baseURL+"jbosstest/UnsecureEJBAccess");
  +      accessURL(url, true);
  +   }
  +
  +   /** Access the http://localhost/jbosstest/other/restricted/test
  +    multiple times to see if the login modules are executed
  +    */
  +   public void testZOtherRestrictedURL() throws Exception
  +   {
  +      if( webServerAvailable == false )
  +         return;
  +      
  +      URL url = new URL(baseURL+"jbosstest/other/restricted/test");
  +      System.out.println("Try #1");
  +      accessURL(url, true);
  +      System.out.println("Try #2");
  +      accessURL(url, true);
  +      System.out.println("Try #3");
         accessURL(url, true);
      }
   
  
  
  

_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to