vmassol     02/02/17 15:36:42

  Modified:    src/framework/share/org/apache/cactus ServletTestCase.java
                        WebTestResult.java
               src/framework/share/org/apache/cactus/server
                        ServletUtil.java
               src/test/share/org/apache/cactus TestAbstractTestCase.java
                        TestAbstractTestCase_InterceptorTestCase.java
               src/test/share/org/apache/cactus/mock
                        MockHttpURLConnection.java
  Log:
  last batch of checkstyle corrections for today ;-)
  
  Revision  Changes    Path
  1.13      +5 -1      
jakarta-cactus/src/framework/share/org/apache/cactus/ServletTestCase.java
  
  Index: ServletTestCase.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-cactus/src/framework/share/org/apache/cactus/ServletTestCase.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- ServletTestCase.java      17 Feb 2002 20:03:24 -0000      1.12
  +++ ServletTestCase.java      17 Feb 2002 23:36:42 -0000      1.13
  @@ -69,7 +69,7 @@
    *
    * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
    *
  - * @version $Id: ServletTestCase.java,v 1.12 2002/02/17 20:03:24 vmassol Exp $
  + * @version $Id: ServletTestCase.java,v 1.13 2002/02/17 23:36:42 vmassol Exp $
    */
   public class ServletTestCase extends AbstractTestCase
   {
  @@ -123,6 +123,10 @@
        * Runs a test case. This method is overriden from the JUnit
        * <code>TestCase</code> class in order to seamlessly call the
        * Cactus redirection servlet.
  +     *
  +     * @exception Throwable if an error happens during the test case
  +     *            execution. All errors are thrown to the JUnit Test
  +     *            Runner which will report them
        */
       protected void runTest() throws Throwable
       {
  
  
  
  1.8       +2 -2      
jakarta-cactus/src/framework/share/org/apache/cactus/WebTestResult.java
  
  Index: WebTestResult.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-cactus/src/framework/share/org/apache/cactus/WebTestResult.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- WebTestResult.java        16 Feb 2002 23:25:49 -0000      1.7
  +++ WebTestResult.java        17 Feb 2002 23:36:42 -0000      1.8
  @@ -67,7 +67,7 @@
    *
    * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
    *
  - * @version $Id: WebTestResult.java,v 1.7 2002/02/16 23:25:49 vmassol Exp $
  + * @version $Id: WebTestResult.java,v 1.8 2002/02/17 23:36:42 vmassol Exp $
    */
   public class WebTestResult implements Serializable
   {
  @@ -147,7 +147,7 @@
       }
   
       /**
  -     * Gives a string representation of the test result
  +     * @see Object#toString()
        */
       public String toString()
       {
  
  
  
  1.9       +3 -2      
jakarta-cactus/src/framework/share/org/apache/cactus/server/ServletUtil.java
  
  Index: ServletUtil.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-cactus/src/framework/share/org/apache/cactus/server/ServletUtil.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- ServletUtil.java  17 Feb 2002 20:03:24 -0000      1.8
  +++ ServletUtil.java  17 Feb 2002 23:36:42 -0000      1.9
  @@ -65,7 +65,7 @@
    *
    * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
    *
  - * @version $Id: ServletUtil.java,v 1.8 2002/02/17 20:03:24 vmassol Exp $
  + * @version $Id: ServletUtil.java,v 1.9 2002/02/17 23:36:42 vmassol Exp $
    */
   public class ServletUtil
   {
  @@ -87,7 +87,8 @@
        *         theParameter does not exist and "" if the parameter exists but
        *         has no value defined in the query string
        */
  -    public static String getQueryStringParameter(String theQueryString, String 
theParameter)
  +    public static String getQueryStringParameter(String theQueryString,
  +            String theParameter)
       {
           if (theQueryString == null) {
               return null;
  
  
  
  1.8       +20 -50    
jakarta-cactus/src/test/share/org/apache/cactus/TestAbstractTestCase.java
  
  Index: TestAbstractTestCase.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-cactus/src/test/share/org/apache/cactus/TestAbstractTestCase.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- TestAbstractTestCase.java 2 Feb 2002 17:54:38 -0000       1.7
  +++ TestAbstractTestCase.java 17 Feb 2002 23:36:42 -0000      1.8
  @@ -1,4 +1,6 @@
   /*
  + * ====================================================================
  + *
    * The Apache Software License, Version 1.1
    *
    * Copyright (c) 2001-2002 The Apache Software Foundation.  All rights
  @@ -23,10 +25,10 @@
    *    Alternately, this acknowlegement may appear in the software itself,
    *    if and wherever such third-party acknowlegements normally appear.
    *
  - * 4. The names "The Jakarta Project", "Cactus", and "Apache Software
  - *    Foundation" must not be used to endorse or promote products derived
  - *    from this software without prior written permission. For written
  - *    permission, please contact [EMAIL PROTECTED]
  + * 4. The names "The Jakarta Project", "Cactus" and "Apache Software
  + *    Foundation" must not be used to endorse or promote products
  + *    derived from this software without prior written permission. For
  + *    written permission, please contact [EMAIL PROTECTED]
    *
    * 5. Products derived from this software may not be called "Apache"
    *    nor may "Apache" appear in their names without prior written
  @@ -50,6 +52,7 @@
    * individuals on behalf of the Apache Software Foundation.  For more
    * information on the Apache Software Foundation, please see
    * <http://www.apache.org/>.
  + *
    */
   package org.apache.cactus;
   
  @@ -65,7 +68,7 @@
    *
    * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
    *
  - * @version $Id: TestAbstractTestCase.java,v 1.7 2002/02/02 17:54:38 vmassol Exp $
  + * @version $Id: TestAbstractTestCase.java,v 1.8 2002/02/17 23:36:42 vmassol Exp $
    */
   public class TestAbstractTestCase extends
       TestAbstractTestCase_InterceptorTestCase
  @@ -110,11 +113,7 @@
       //-------------------------------------------------------------------------
   
       /**
  -     * Test that when a begin method for a given test does not have the correct
  -     * return type (i.e. void), a <code>AssertionFailedError</code> exception
  -     * is returned.
  -     * Note: the assert is done in the
  -     * <code>TestAbstractTestCase_InterceptorTestCase</code> class.
  +     * @see #testBeginMethodBadReturnType()
        */
       public String beginBeginMethodBadReturnType(WebRequest theRequest)
       {
  @@ -141,10 +140,7 @@
       //-------------------------------------------------------------------------
   
       /**
  -     * Test that when a begin method for a given test is not declared public
  -     * a <code>AssertionFailedError</code> exception is returned.
  -     * Note: the assert is done in the
  -     * <code>TestAbstractTestCase_InterceptorTestCase</code> class.
  +     * @see #testBeginMethodNotPublic()
        */
       private void beginBeginMethodNotPublic(WebRequest theRequest)
       {
  @@ -168,10 +164,7 @@
       //-------------------------------------------------------------------------
   
       /**
  -     * Test that when a begin method for a given test has the wrong type of
  -     * parameters, a <code>AssertionFailedError</code> exception is returned.
  -     * Note: the assert is done in the
  -     * <code>TestAbstractTestCase_InterceptorTestCase</code> class.
  +     * @see #testBeginMethodBadReturnType()
        */
       public void beginBeginMethodBadParamType(String theDummy)
       {
  @@ -195,10 +188,7 @@
       //-------------------------------------------------------------------------
   
       /**
  -     * Test that when a begin method for a given test has the wrong number of
  -     * parameters, a <code>AssertionFailedError</code> exception is returned.
  -     * Note: the assert is done in the
  -     * <code>TestAbstractTestCase_InterceptorTestCase</code> class.
  +     * @see #testBeginMethodBadParamNumber()
        */
       public void beginBeginMethodBadParamNumber(WebRequest theRequest,
           String theString)
  @@ -223,8 +213,7 @@
       //-------------------------------------------------------------------------
   
       /**
  -     * Verify that the begin method with a
  -     * <code>WebRequest</code> parameter is called correctly.
  +     * @see #testBeginMethodOK()
        */
       public void beginBeginMethodOK(WebRequest theRequest)
       {
  @@ -258,11 +247,7 @@
       }
   
       /**
  -     * Test that when an end method for a given test does not have the correct
  -     * return type (i.e. void), a <code>AssertionFailedError</code> exception
  -     * is returned.
  -     * Note: the assert is done in the
  -     * <code>TestAbstractTestCase_InterceptorTestCase</code> class.
  +     * @see #testEndMethodBadReturnType()
        */
       public String endEndMethodBadReturnType(WebResponse theResponse)
       {
  @@ -283,10 +268,7 @@
       }
   
       /**
  -     * Test that when an end method for a given test is not declared public
  -     * a <code>AssertionFailedError</code> exception is returned.
  -     * Note: the assert is done in the
  -     * <code>TestAbstractTestCase_InterceptorTestCase</code> class.
  +     * @see #testEndMethodNotPublic()
        */
       private void endEndMethodNotPublic(WebResponse theResponse)
       {
  @@ -305,10 +287,7 @@
       }
   
       /**
  -     * Test that when an end method for a given test has the wrong type of
  -     * parameters, a <code>AssertionFailedError</code> exception is returned.
  -     * Note: the assert is done in the
  -     * <code>TestAbstractTestCase_InterceptorTestCase</code> class.
  +     * @see #testEndMethodBadParamType()
        */
       public void endEndMethodBadParamType(String theDummy)
       {
  @@ -327,10 +306,7 @@
       }
   
       /**
  -     * Test that when an end method for a given test has the wrong number of
  -     * parameters, a <code>AssertionFailedError</code> exception is returned.
  -     * Note: the assert is done in the
  -     * <code>TestAbstractTestCase_InterceptorTestCase</code> class.
  +     * @see #testEndMethodBadParamNumber()
        */
       public void endEndMethodBadParamNumber(WebResponse theResponse,
           String theDummy)
  @@ -348,8 +324,7 @@
       }
   
       /**
  -     * Test that the end method is called correctly when it's signature
  -     * contains a <code>org.apache.cactus.WebResponse</code> parameter.
  +     * @see #testEndMethodOK1()
        */
       public void endEndMethodOK1(WebResponse theResponse)
       {
  @@ -373,11 +348,7 @@
       }
   
       /**
  -     * Test that the end method is called correctly when it's signature
  -     * contains a <code>com.meterware.httpunit.WebResponse</code> parameter.
  -     *
  -     * Note: We need the Httpunit jar and an XML parser jar on the classpath
  -     * for this test
  +     * @see #testEndMethodOK2()
        */
       public void endEndMethodOK2(com.meterware.httpunit.WebResponse theResponse)
       {
  @@ -398,8 +369,7 @@
       }
   
       /**
  -     * Test that the deprecated end method with the
  -     * <code>HttpURLConnection</code> parameter can still be called correctly.
  +     * @see #testEndMethodOK3()
        */
       public void endEndMethodOK3(HttpURLConnection theResponse)
       {
  
  
  
  1.14      +8 -5      
jakarta-cactus/src/test/share/org/apache/cactus/TestAbstractTestCase_InterceptorTestCase.java
  
  Index: TestAbstractTestCase_InterceptorTestCase.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-cactus/src/test/share/org/apache/cactus/TestAbstractTestCase_InterceptorTestCase.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -r1.13 -r1.14
  --- TestAbstractTestCase_InterceptorTestCase.java     2 Feb 2002 17:54:38 -0000      
 1.13
  +++ TestAbstractTestCase_InterceptorTestCase.java     17 Feb 2002 23:36:42 -0000     
 1.14
  @@ -1,4 +1,6 @@
   /*
  + * ====================================================================
  + *
    * The Apache Software License, Version 1.1
    *
    * Copyright (c) 2001-2002 The Apache Software Foundation.  All rights
  @@ -23,10 +25,10 @@
    *    Alternately, this acknowlegement may appear in the software itself,
    *    if and wherever such third-party acknowlegements normally appear.
    *
  - * 4. The names "The Jakarta Project", "Cactus", and "Apache Software
  - *    Foundation" must not be used to endorse or promote products derived
  - *    from this software without prior written permission. For written
  - *    permission, please contact [EMAIL PROTECTED]
  + * 4. The names "The Jakarta Project", "Cactus" and "Apache Software
  + *    Foundation" must not be used to endorse or promote products
  + *    derived from this software without prior written permission. For
  + *    written permission, please contact [EMAIL PROTECTED]
    *
    * 5. Products derived from this software may not be called "Apache"
    *    nor may "Apache" appear in their names without prior written
  @@ -50,6 +52,7 @@
    * individuals on behalf of the Apache Software Foundation.  For more
    * information on the Apache Software Foundation, please see
    * <http://www.apache.org/>.
  + *
    */
   package org.apache.cactus;
   
  @@ -67,7 +70,7 @@
    *
    * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
    *
  - * @version $Id: TestAbstractTestCase_InterceptorTestCase.java,v 1.13 2002/02/02 
17:54:38 vmassol Exp $
  + * @version $Id: TestAbstractTestCase_InterceptorTestCase.java,v 1.14 2002/02/17 
23:36:42 vmassol Exp $
    */
   public class TestAbstractTestCase_InterceptorTestCase
       extends AbstractTestCase
  
  
  
  1.8       +24 -12    
jakarta-cactus/src/test/share/org/apache/cactus/mock/MockHttpURLConnection.java
  
  Index: MockHttpURLConnection.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-cactus/src/test/share/org/apache/cactus/mock/MockHttpURLConnection.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- MockHttpURLConnection.java        2 Feb 2002 17:54:38 -0000       1.7
  +++ MockHttpURLConnection.java        17 Feb 2002 23:36:42 -0000      1.8
  @@ -1,4 +1,6 @@
   /*
  + * ====================================================================
  + *
    * The Apache Software License, Version 1.1
    *
    * Copyright (c) 2001-2002 The Apache Software Foundation.  All rights
  @@ -23,10 +25,10 @@
    *    Alternately, this acknowlegement may appear in the software itself,
    *    if and wherever such third-party acknowlegements normally appear.
    *
  - * 4. The names "The Jakarta Project", "Cactus", and "Apache Software
  - *    Foundation" must not be used to endorse or promote products derived
  - *    from this software without prior written permission. For written
  - *    permission, please contact [EMAIL PROTECTED]
  + * 4. The names "The Jakarta Project", "Cactus" and "Apache Software
  + *    Foundation" must not be used to endorse or promote products
  + *    derived from this software without prior written permission. For
  + *    written permission, please contact [EMAIL PROTECTED]
    *
    * 5. Products derived from this software may not be called "Apache"
    *    nor may "Apache" appear in their names without prior written
  @@ -50,6 +52,7 @@
    * individuals on behalf of the Apache Software Foundation.  For more
    * information on the Apache Software Foundation, please see
    * <http://www.apache.org/>.
  + *
    */
   package org.apache.cactus.mock;
   
  @@ -62,7 +65,7 @@
    *
    * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
    *
  - * @version $Id: MockHttpURLConnection.java,v 1.7 2002/02/02 17:54:38 vmassol Exp $
  + * @version $Id: MockHttpURLConnection.java,v 1.8 2002/02/17 23:36:42 vmassol Exp $
    */
   public class MockHttpURLConnection extends HttpURLConnection
   {
  @@ -117,25 +120,25 @@
       }
   
       /**
  -     * See <code>java.net.URLConnection.getHeaderField</code>.
  +     * @see HttpURLConnection#getHeaderField(int)
        */
  -    public String getHeaderField(int fieldNumber)
  +    public String getHeaderField(int theFieldNumber)
       {
           if (this.getHeaderFieldValue == null) {
  -            throw new RuntimeException("Must call setExpectedGetHeaderField() " +
  -                "first !");
  +            throw new RuntimeException(
  +                "Must call setExpectedGetHeaderField() first !");
           }
           return this.getHeaderFieldValue;
       }
   
       /**
  -     * See <code>java.net.URLConnection.getInputStream</code>.
  +     * @see HttpURLConnection#getInputStream()
        */
       public InputStream getInputStream()
       {
           if (this.getInputStreamValue == null) {
  -            throw new RuntimeException("Must call setExpectedGetInputStream() " +
  -                "first !");
  +            throw new RuntimeException(
  +                "Must call setExpectedGetInputStream() first !");
           }
           return this.getInputStreamValue;
       }
  @@ -144,15 +147,24 @@
       // Methods needed because HttpURLConnection is an abstract class
       // -----------------------------------------------------------------------
   
  +    /**
  +     * @see HttpURLConnection#usingProxy()
  +     */
       public boolean usingProxy()
       {
           return false;
       }
   
  +    /**
  +     * @see HttpURLConnection#disconnect()
  +     */
       public void disconnect()
       {
       }
   
  +    /**
  +     * @see HttpURLConnection#connect()
  +     */
       public void connect()
       {
       }
  
  
  

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

Reply via email to