tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lar...@apache.org
Subject cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/util/test/matchers HttpStatusMatch.java ResponseMatch.java
Date Thu, 01 Mar 2001 17:56:28 GMT
larryi      01/03/01 09:56:28

  Modified:    src/share/org/apache/tomcat/util/test/matchers
                        HttpStatusMatch.java ResponseMatch.java
  Log:
  Update log output so you can tell if matching for true or false.
  
  Revision  Changes    Path
  1.2       +5 -2      jakarta-tomcat/src/share/org/apache/tomcat/util/test/matchers/HttpStatusMatch.java
  
  Index: HttpStatusMatch.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/util/test/matchers/HttpStatusMatch.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- HttpStatusMatch.java	2001/02/09 03:48:17	1.1
  +++ HttpStatusMatch.java	2001/03/01 17:56:21	1.2
  @@ -124,8 +124,11 @@
   			     responseLine.indexOf(returnCode) > -1);
   	    if( match != testCondition ) {
   		responseStatus = false;
  -		log("    Expecting: " + returnCode );
  -		log("    Got      : " + responseLine);
  +		if( testCondition )
  +		    log("    Expecting    : " + returnCode );
  +		else
  +		    log("    Not Expecting: " + returnCode );
  +		log("    Got          : " + responseLine);
   	    }
   	}
   
  
  
  
  1.2       +4 -1      jakarta-tomcat/src/share/org/apache/tomcat/util/test/matchers/ResponseMatch.java
  
  Index: ResponseMatch.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/util/test/matchers/ResponseMatch.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ResponseMatch.java	2001/02/09 03:48:17	1.1
  +++ ResponseMatch.java	2001/03/01 17:56:23	1.2
  @@ -127,7 +127,10 @@
   	    boolean match=responseBody.indexOf( responseMatch ) >= 0; 
   	    if( match != testCondition ) {
   		responseStatus = false;
  -		log("ERROR: expecting match on " + responseMatch);
  +		if( testCondition )
  +		    log("ERROR: expecting match on " + responseMatch);
  +		else
  +		    log("ERROR: expecting no match on " + responseMatch);
   		log("GOT: " );
   		log(responseBody );
   	    }
  
  
  

Mime
View raw message