sullis      2002/10/09 10:20:44

  Modified:    lang/src/test/org/apache/commons/lang/exception
                        NestableExceptionTestCase.java
  Log:
  cleaned up exception handling in the serialization test code
  
  Revision  Changes    Path
  1.7       +4 -8      
jakarta-commons/lang/src/test/org/apache/commons/lang/exception/NestableExceptionTestCase.java
  
  Index: NestableExceptionTestCase.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-commons/lang/src/test/org/apache/commons/lang/exception/NestableExceptionTestCase.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- NestableExceptionTestCase.java    9 Oct 2002 05:28:53 -0000       1.6
  +++ NestableExceptionTestCase.java    9 Oct 2002 17:20:44 -0000       1.7
  @@ -247,6 +247,7 @@
       }
       
       public void testSerialization()
  +     throws java.io.IOException, ClassNotFoundException
       {
        RuntimeException nestedEx = new RuntimeException("nested exception message");
        NestableExceptionTester1 ex = new NestableExceptionTester1("serialization 
test", nestedEx);
  @@ -259,9 +260,9 @@
                ByteArrayInputStream bais = null;
                ObjectOutputStream oos = null;
                ObjectInputStream ois = null;
  -             
  +
                try
  -             {
  +             {               
                        oos = new ObjectOutputStream(baos);
                        oos.writeObject(ex);
                        oos.flush();
  @@ -285,11 +286,6 @@
                                        t.getMessage(),
                                        deserializedThrowable.getMessage());
                        }
  -             }
  -             catch (Exception caughtEx)
  -             {
  -                     fail("an unexpected exception occurred: "
  -                                     + caughtEx.toString());
                }
                finally
                {
  
  
  

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

Reply via email to