rlubke      01/12/19 17:09:36

  Modified:    src/tools/org/apache/tomcat/task GTest.java
  Log:
  Added functionality to allow test writers to expect multiple response
  headers from the server by delimiting individual headers with a pipe '|'.
  
  The gtest task would look something like:
    <gtest request=<some_request>
       debug="0" host="${host}" port="${port}"
       expectHeaders="MyHeader:val1|MyHeader:val2"
    />
  
  Revision  Changes    Path
  1.7       +5 -1      jakarta-watchdog-4.0/src/tools/org/apache/tomcat/task/GTest.java
  
  Index: GTest.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-watchdog-4.0/src/tools/org/apache/tomcat/task/GTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- GTest.java        2001/12/18 18:58:20     1.6
  +++ GTest.java        2001/12/20 01:09:36     1.7
  @@ -306,7 +306,11 @@
        */
       public void setExpectHeaders( String s ) {
           this.expectHeaders = new HashMap();
  -        getHeaderDetails( s, expectHeaders, false );
  +        StringTokenizer tok = new StringTokenizer( s, "|" );
  +        while ( tok.hasMoreElements() ) {
  +            String header = (String) tok.nextElement();
  +            getHeaderDetails( header, expectHeaders, false );
  +        }
       }
   
       /**
  
  
  

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to