harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From smish...@apache.org
Subject svn commit: r443293 - in /incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test: java/common/org/apache/harmony/nio/tests/java/nio/channels/ resources/serialization/java/nio/channels/ resources/serialization/org/apache/harmony/nio/tests/java/n...
Date Thu, 14 Sep 2006 09:17:33 GMT
Author: smishura
Date: Thu Sep 14 02:17:30 2006
New Revision: 443293

URL: http://svn.apache.org/viewvc?view=rev&rev=443293
Log:
Organize nio tests: refactoring java.nio.channels serialization tests to use new testing framework

Added:
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/org/apache/harmony/nio/tests/java/nio/channels/AlreadyConnectedExceptionTest.golden.ser
      - copied unchanged from r443253, incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/AlreadyConnectedExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/org/apache/harmony/nio/tests/java/nio/channels/AsynchronousCloseExceptionTest.golden.ser
      - copied unchanged from r443253, incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/AsynchronousCloseExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/org/apache/harmony/nio/tests/java/nio/channels/CancelledKeyExceptionTest.golden.ser
      - copied unchanged from r443253, incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/CancelledKeyExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/org/apache/harmony/nio/tests/java/nio/channels/ClosedByInterruptExceptionTest.golden.ser
      - copied unchanged from r443253, incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/ClosedByInterruptExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/org/apache/harmony/nio/tests/java/nio/channels/ClosedChannelExceptionTest.golden.ser
      - copied unchanged from r443253, incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/ClosedChannelExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/org/apache/harmony/nio/tests/java/nio/channels/ClosedSelectorExceptionTest.golden.ser
      - copied unchanged from r443253, incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/ClosedSelectorExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/org/apache/harmony/nio/tests/java/nio/channels/ConnectionPendingExceptionTest.golden.ser
      - copied unchanged from r443253, incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/ConnectionPendingExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/org/apache/harmony/nio/tests/java/nio/channels/FileLockInterruptionExceptionTest.golden.ser
      - copied unchanged from r443253, incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/FileLockInterruptionExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/org/apache/harmony/nio/tests/java/nio/channels/IllegalBlockingModeExceptionTest.golden.ser
      - copied unchanged from r443253, incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/IllegalBlockingModeExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/org/apache/harmony/nio/tests/java/nio/channels/IllegalSelectorExceptionTest.golden.ser
      - copied unchanged from r443253, incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/IllegalSelectorExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/org/apache/harmony/nio/tests/java/nio/channels/NoConnectionPendingExceptionTest.golden.ser
      - copied unchanged from r443253, incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/NoConnectionPendingExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/org/apache/harmony/nio/tests/java/nio/channels/NonReadableChannelExceptionTest.golden.ser
      - copied unchanged from r443253, incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/NonReadableChannelExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/org/apache/harmony/nio/tests/java/nio/channels/NonWritableChannelExceptionTest.golden.ser
      - copied unchanged from r443253, incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/NonWritableChannelExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/org/apache/harmony/nio/tests/java/nio/channels/NotYetBoundExceptionTest.golden.ser
      - copied unchanged from r443253, incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/NotYetBoundExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/org/apache/harmony/nio/tests/java/nio/channels/NotYetConnectedExceptionTest.golden.ser
      - copied unchanged from r443253, incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/NotYetConnectedExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/org/apache/harmony/nio/tests/java/nio/channels/OverlappingFileLockExceptionTest.golden.ser
      - copied unchanged from r443253, incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/OverlappingFileLockExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/org/apache/harmony/nio/tests/java/nio/channels/UnresolvedAddressExceptionTest.golden.ser
      - copied unchanged from r443253, incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/UnresolvedAddressExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/org/apache/harmony/nio/tests/java/nio/channels/UnsupportedAddressTypeExceptionTest.golden.ser
      - copied unchanged from r443253, incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/UnsupportedAddressTypeExceptionTest.golden.ser
Removed:
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/AlreadyConnectedExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/AsynchronousCloseExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/CancelledKeyExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/ClosedByInterruptExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/ClosedChannelExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/ClosedSelectorExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/ConnectionPendingExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/FileLockInterruptionExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/IllegalBlockingModeExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/IllegalSelectorExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/NoConnectionPendingExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/NonReadableChannelExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/NonWritableChannelExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/NotYetBoundExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/NotYetConnectedExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/OverlappingFileLockExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/UnresolvedAddressExceptionTest.golden.ser
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/UnsupportedAddressTypeExceptionTest.golden.ser
Modified:
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/AlreadyConnectedExceptionTest.java
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/AsynchronousCloseExceptionTest.java
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/CancelledKeyExceptionTest.java
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/ClosedByInterruptExceptionTest.java
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/ClosedChannelExceptionTest.java
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/ClosedSelectorExceptionTest.java
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/ConnectionPendingExceptionTest.java
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/FileLockInterruptionExceptionTest.java
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/IllegalBlockingModeExceptionTest.java
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/IllegalSelectorExceptionTest.java
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NoConnectionPendingExceptionTest.java
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NonReadableChannelExceptionTest.java
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NonWritableChannelExceptionTest.java
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NotYetBoundExceptionTest.java
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NotYetConnectedExceptionTest.java
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/OverlappingFileLockExceptionTest.java
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/UnresolvedAddressExceptionTest.java
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/UnsupportedAddressTypeExceptionTest.java

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/AlreadyConnectedExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/AlreadyConnectedExceptionTest.java?view=diff&rev=443293&r1=443292&r2=443293
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/AlreadyConnectedExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/AlreadyConnectedExceptionTest.java Thu Sep 14 02:17:30 2006
@@ -14,11 +14,11 @@
  */
 package org.apache.harmony.nio.tests.java.nio.channels;
 
-import java.io.IOException;
 import java.nio.channels.AlreadyConnectedException;
 
 import junit.framework.TestCase;
-import tests.util.SerializationTester;
+
+import org.apache.harmony.testframework.serialization.SerializationTest;
 
 /**
  * Tests for AlreadyConnectedException
@@ -28,21 +28,16 @@
     /**
      * @tests serialization/deserialization compatibility.
      */
-    public void test_serialization() throws IOException, ClassNotFoundException {
-        AlreadyConnectedException object = new AlreadyConnectedException();
-        AlreadyConnectedException deObject = (AlreadyConnectedException) SerializationTester
-                .getDeserilizedObject(object);
-        assertNotNull(deObject);
+    public void testSerializationSelf() throws Exception {
+
+        SerializationTest.verifySelf(new AlreadyConnectedException());
     }
 
     /**
      * @tests serialization/deserialization compatibility with RI.
      */
-    public void test_compatibilitySerialization() throws Exception {
-        AlreadyConnectedException object = new AlreadyConnectedException();
-        AlreadyConnectedException deObject = (AlreadyConnectedException) SerializationTester
-                .readObject(object,
-                        "serialization/java/nio/channels/AlreadyConnectedExceptionTest.golden.ser");
-        assertNotNull(deObject);
+    public void testSerializationCompatibility() throws Exception {
+
+        SerializationTest.verifyGolden(this, new AlreadyConnectedException());
     }
-}
\ No newline at end of file
+}

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/AsynchronousCloseExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/AsynchronousCloseExceptionTest.java?view=diff&rev=443293&r1=443292&r2=443293
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/AsynchronousCloseExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/AsynchronousCloseExceptionTest.java Thu Sep 14 02:17:30 2006
@@ -14,11 +14,11 @@
  */
 package org.apache.harmony.nio.tests.java.nio.channels;
 
-import java.io.IOException;
 import java.nio.channels.AsynchronousCloseException;
 
 import junit.framework.TestCase;
-import tests.util.SerializationTester;
+
+import org.apache.harmony.testframework.serialization.SerializationTest;
 
 /**
  * Tests for AsynchronousCloseException
@@ -28,21 +28,16 @@
     /**
      * @tests serialization/deserialization compatibility.
      */
-    public void test_serialization() throws IOException, ClassNotFoundException {
-        AsynchronousCloseException object = new AsynchronousCloseException();
-        AsynchronousCloseException deObject = (AsynchronousCloseException) SerializationTester
-                .getDeserilizedObject(object);
-        assertNotNull(deObject);
+    public void testSerializationSelf() throws Exception {
+
+        SerializationTest.verifySelf(new AsynchronousCloseException());
     }
 
     /**
      * @tests serialization/deserialization compatibility with RI.
      */
-    public void test_compatibilitySerialization() throws Exception {
-        AsynchronousCloseException object = new AsynchronousCloseException();
-        AsynchronousCloseException deObject = (AsynchronousCloseException) SerializationTester
-                .readObject(object,
-                        "serialization/java/nio/channels/AsynchronousCloseExceptionTest.golden.ser");
-        assertNotNull(deObject);
+    public void testSerializationCompatibility() throws Exception {
+
+        SerializationTest.verifyGolden(this, new AsynchronousCloseException());
     }
 }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/CancelledKeyExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/CancelledKeyExceptionTest.java?view=diff&rev=443293&r1=443292&r2=443293
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/CancelledKeyExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/CancelledKeyExceptionTest.java Thu Sep 14 02:17:30 2006
@@ -14,11 +14,11 @@
  */
 package org.apache.harmony.nio.tests.java.nio.channels;
 
-import java.io.IOException;
 import java.nio.channels.CancelledKeyException;
 
 import junit.framework.TestCase;
-import tests.util.SerializationTester;
+
+import org.apache.harmony.testframework.serialization.SerializationTest;
 
 /**
  * Tests for CancelledKeyException
@@ -28,21 +28,16 @@
     /**
      * @tests serialization/deserialization compatibility.
      */
-    public void test_serialization() throws IOException, ClassNotFoundException {
-        CancelledKeyException object = new CancelledKeyException();
-        CancelledKeyException deObject = (CancelledKeyException) SerializationTester
-                .getDeserilizedObject(object);
-        assertNotNull(deObject);
+    public void testSerializationSelf() throws Exception {
+
+        SerializationTest.verifySelf(new CancelledKeyException());
     }
 
     /**
      * @tests serialization/deserialization compatibility with RI.
      */
-    public void test_compatibilitySerialization() throws Exception {
-        CancelledKeyException object = new CancelledKeyException();
-        CancelledKeyException deObject = (CancelledKeyException) SerializationTester
-                .readObject(object,
-                        "serialization/java/nio/channels/CancelledKeyExceptionTest.golden.ser");
-        assertNotNull(deObject);
+    public void testSerializationCompatibility() throws Exception {
+
+        SerializationTest.verifyGolden(this, new CancelledKeyException());
     }
 }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/ClosedByInterruptExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/ClosedByInterruptExceptionTest.java?view=diff&rev=443293&r1=443292&r2=443293
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/ClosedByInterruptExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/ClosedByInterruptExceptionTest.java Thu Sep 14 02:17:30 2006
@@ -14,11 +14,11 @@
  */
 package org.apache.harmony.nio.tests.java.nio.channels;
 
-import java.io.IOException;
 import java.nio.channels.ClosedByInterruptException;
 
 import junit.framework.TestCase;
-import tests.util.SerializationTester;
+
+import org.apache.harmony.testframework.serialization.SerializationTest;
 
 /**
  * Tests for ClosedByInterruptException
@@ -28,21 +28,16 @@
     /**
      * @tests serialization/deserialization compatibility.
      */
-    public void test_serialization() throws IOException, ClassNotFoundException {
-        ClosedByInterruptException object = new ClosedByInterruptException();
-        ClosedByInterruptException deObject = (ClosedByInterruptException) SerializationTester
-                .getDeserilizedObject(object);
-        assertNotNull(deObject);
+    public void testSerializationSelf() throws Exception {
+
+        SerializationTest.verifySelf(new ClosedByInterruptException());
     }
 
     /**
      * @tests serialization/deserialization compatibility with RI.
      */
-    public void test_compatibilitySerialization() throws Exception {
-        ClosedByInterruptException object = new ClosedByInterruptException();
-        ClosedByInterruptException deObject = (ClosedByInterruptException) SerializationTester
-                .readObject(object,
-                        "serialization/java/nio/channels/ClosedByInterruptExceptionTest.golden.ser");
-        assertNotNull(deObject);
+    public void testSerializationCompatibility() throws Exception {
+
+        SerializationTest.verifyGolden(this, new ClosedByInterruptException());
     }
 }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/ClosedChannelExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/ClosedChannelExceptionTest.java?view=diff&rev=443293&r1=443292&r2=443293
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/ClosedChannelExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/ClosedChannelExceptionTest.java Thu Sep 14 02:17:30 2006
@@ -14,11 +14,11 @@
  */
 package org.apache.harmony.nio.tests.java.nio.channels;
 
-import java.io.IOException;
 import java.nio.channels.ClosedChannelException;
 
 import junit.framework.TestCase;
-import tests.util.SerializationTester;
+
+import org.apache.harmony.testframework.serialization.SerializationTest;
 
 /**
  * Tests for ClosedChannelException
@@ -28,21 +28,16 @@
     /**
      * @tests serialization/deserialization compatibility.
      */
-    public void test_serialization() throws IOException, ClassNotFoundException {
-        ClosedChannelException object = new ClosedChannelException();
-        ClosedChannelException deObject = (ClosedChannelException) SerializationTester
-                .getDeserilizedObject(object);
-        assertNotNull(deObject);
+    public void testSerializationSelf() throws Exception {
+
+        SerializationTest.verifySelf(new ClosedChannelException());
     }
 
     /**
      * @tests serialization/deserialization compatibility with RI.
      */
-    public void test_compatibilitySerialization() throws Exception {
-        ClosedChannelException object = new ClosedChannelException();
-        ClosedChannelException deObject = (ClosedChannelException) SerializationTester
-                .readObject(object,
-                        "serialization/java/nio/channels/ClosedChannelExceptionTest.golden.ser");
-        assertNotNull(deObject);
+    public void testSerializationCompatibility() throws Exception {
+
+        SerializationTest.verifyGolden(this, new ClosedChannelException());
     }
 }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/ClosedSelectorExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/ClosedSelectorExceptionTest.java?view=diff&rev=443293&r1=443292&r2=443293
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/ClosedSelectorExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/ClosedSelectorExceptionTest.java Thu Sep 14 02:17:30 2006
@@ -14,11 +14,11 @@
  */
 package org.apache.harmony.nio.tests.java.nio.channels;
 
-import java.io.IOException;
 import java.nio.channels.ClosedSelectorException;
 
 import junit.framework.TestCase;
-import tests.util.SerializationTester;
+
+import org.apache.harmony.testframework.serialization.SerializationTest;
 
 /**
  * Tests for ClosedSelectorException
@@ -28,21 +28,16 @@
     /**
      * @tests serialization/deserialization compatibility.
      */
-    public void test_serialization() throws IOException, ClassNotFoundException {
-        ClosedSelectorException object = new ClosedSelectorException();
-        ClosedSelectorException deObject = (ClosedSelectorException) SerializationTester
-                .getDeserilizedObject(object);
-        assertNotNull(deObject);
+    public void testSerializationSelf() throws Exception {
+
+        SerializationTest.verifySelf(new ClosedSelectorException());
     }
 
     /**
      * @tests serialization/deserialization compatibility with RI.
      */
-    public void test_compatibilitySerialization() throws Exception {
-        ClosedSelectorException object = new ClosedSelectorException();
-        ClosedSelectorException deObject = (ClosedSelectorException) SerializationTester
-                .readObject(object,
-                        "serialization/java/nio/channels/ClosedSelectorExceptionTest.golden.ser");
-        assertNotNull(deObject);
+    public void testSerializationCompatibility() throws Exception {
+
+        SerializationTest.verifyGolden(this, new ClosedSelectorException());
     }
 }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/ConnectionPendingExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/ConnectionPendingExceptionTest.java?view=diff&rev=443293&r1=443292&r2=443293
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/ConnectionPendingExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/ConnectionPendingExceptionTest.java Thu Sep 14 02:17:30 2006
@@ -14,11 +14,11 @@
  */
 package org.apache.harmony.nio.tests.java.nio.channels;
 
-import java.io.IOException;
 import java.nio.channels.ConnectionPendingException;
 
 import junit.framework.TestCase;
-import tests.util.SerializationTester;
+
+import org.apache.harmony.testframework.serialization.SerializationTest;
 
 /**
  * Tests for ConnectionPendingException
@@ -28,21 +28,16 @@
     /**
      * @tests serialization/deserialization compatibility.
      */
-    public void test_serialization() throws IOException, ClassNotFoundException {
-        ConnectionPendingException object = new ConnectionPendingException();
-        ConnectionPendingException deObject = (ConnectionPendingException) SerializationTester
-                .getDeserilizedObject(object);
-        assertNotNull(deObject);
+    public void testSerializationSelf() throws Exception {
+
+        SerializationTest.verifySelf(new ConnectionPendingException());
     }
 
     /**
      * @tests serialization/deserialization compatibility with RI.
      */
-    public void test_compatibilitySerialization() throws Exception {
-        ConnectionPendingException object = new ConnectionPendingException();
-        ConnectionPendingException deObject = (ConnectionPendingException) SerializationTester
-                .readObject(object,
-                        "serialization/java/nio/channels/ConnectionPendingExceptionTest.golden.ser");
-        assertNotNull(deObject);
+    public void testSerializationCompatibility() throws Exception {
+
+        SerializationTest.verifyGolden(this, new ConnectionPendingException());
     }
 }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/FileLockInterruptionExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/FileLockInterruptionExceptionTest.java?view=diff&rev=443293&r1=443292&r2=443293
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/FileLockInterruptionExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/FileLockInterruptionExceptionTest.java Thu Sep 14 02:17:30 2006
@@ -14,11 +14,11 @@
  */
 package org.apache.harmony.nio.tests.java.nio.channels;
 
-import java.io.IOException;
 import java.nio.channels.FileLockInterruptionException;
 
 import junit.framework.TestCase;
-import tests.util.SerializationTester;
+
+import org.apache.harmony.testframework.serialization.SerializationTest;
 
 /**
  * Tests for FileLockInterruptionException
@@ -28,21 +28,17 @@
     /**
      * @tests serialization/deserialization compatibility.
      */
-    public void test_serialization() throws IOException, ClassNotFoundException {
-        FileLockInterruptionException object = new FileLockInterruptionException();
-        FileLockInterruptionException deObject = (FileLockInterruptionException) SerializationTester
-                .getDeserilizedObject(object);
-        assertNotNull(deObject);
+    public void testSerializationSelf() throws Exception {
+
+        SerializationTest.verifySelf(new FileLockInterruptionException());
     }
 
     /**
      * @tests serialization/deserialization compatibility with RI.
      */
-    public void test_compatibilitySerialization() throws Exception {
-        FileLockInterruptionException object = new FileLockInterruptionException();
-        FileLockInterruptionException deObject = (FileLockInterruptionException) SerializationTester
-                .readObject(object,
-                        "serialization/java/nio/channels/FileLockInterruptionExceptionTest.golden.ser");
-        assertNotNull(deObject);
+    public void testSerializationCompatibility() throws Exception {
+
+        SerializationTest.verifyGolden(this,
+                new FileLockInterruptionException());
     }
 }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/IllegalBlockingModeExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/IllegalBlockingModeExceptionTest.java?view=diff&rev=443293&r1=443292&r2=443293
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/IllegalBlockingModeExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/IllegalBlockingModeExceptionTest.java Thu Sep 14 02:17:30 2006
@@ -14,11 +14,11 @@
  */
 package org.apache.harmony.nio.tests.java.nio.channels;
 
-import java.io.IOException;
 import java.nio.channels.IllegalBlockingModeException;
 
 import junit.framework.TestCase;
-import tests.util.SerializationTester;
+
+import org.apache.harmony.testframework.serialization.SerializationTest;
 
 /**
  * Tests for IllegalBlockingModeException
@@ -28,21 +28,17 @@
     /**
      * @tests serialization/deserialization compatibility.
      */
-    public void test_serialization() throws IOException, ClassNotFoundException {
-        IllegalBlockingModeException object = new IllegalBlockingModeException();
-        IllegalBlockingModeException deObject = (IllegalBlockingModeException) SerializationTester
-                .getDeserilizedObject(object);
-        assertNotNull(deObject);
+    public void testSerializationSelf() throws Exception {
+
+        SerializationTest.verifySelf(new IllegalBlockingModeException());
     }
 
     /**
      * @tests serialization/deserialization compatibility with RI.
      */
-    public void test_compatibilitySerialization() throws Exception {
-        IllegalBlockingModeException object = new IllegalBlockingModeException();
-        IllegalBlockingModeException deObject = (IllegalBlockingModeException) SerializationTester
-                .readObject(object,
-                        "serialization/java/nio/channels/IllegalBlockingModeExceptionTest.golden.ser");
-        assertNotNull(deObject);
+    public void testSerializationCompatibility() throws Exception {
+
+        SerializationTest
+                .verifyGolden(this, new IllegalBlockingModeException());
     }
 }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/IllegalSelectorExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/IllegalSelectorExceptionTest.java?view=diff&rev=443293&r1=443292&r2=443293
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/IllegalSelectorExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/IllegalSelectorExceptionTest.java Thu Sep 14 02:17:30 2006
@@ -14,11 +14,11 @@
  */
 package org.apache.harmony.nio.tests.java.nio.channels;
 
-import java.io.IOException;
 import java.nio.channels.IllegalSelectorException;
 
 import junit.framework.TestCase;
-import tests.util.SerializationTester;
+
+import org.apache.harmony.testframework.serialization.SerializationTest;
 
 /**
  * Tests for IllegalSelectorException
@@ -28,21 +28,16 @@
     /**
      * @tests serialization/deserialization compatibility.
      */
-    public void test_serialization() throws IOException, ClassNotFoundException {
-        IllegalSelectorException object = new IllegalSelectorException();
-        IllegalSelectorException deObject = (IllegalSelectorException) SerializationTester
-                .getDeserilizedObject(object);
-        assertNotNull(deObject);
+    public void testSerializationSelf() throws Exception {
+
+        SerializationTest.verifySelf(new IllegalSelectorException());
     }
 
     /**
      * @tests serialization/deserialization compatibility with RI.
      */
-    public void test_compatibilitySerialization() throws Exception {
-        IllegalSelectorException object = new IllegalSelectorException();
-        IllegalSelectorException deObject = (IllegalSelectorException) SerializationTester
-                .readObject(object,
-                        "serialization/java/nio/channels/IllegalSelectorExceptionTest.golden.ser");
-        assertNotNull(deObject);
+    public void testSerializationCompatibility() throws Exception {
+
+        SerializationTest.verifyGolden(this, new IllegalSelectorException());
     }
 }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NoConnectionPendingExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NoConnectionPendingExceptionTest.java?view=diff&rev=443293&r1=443292&r2=443293
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NoConnectionPendingExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NoConnectionPendingExceptionTest.java Thu Sep 14 02:17:30 2006
@@ -14,11 +14,11 @@
  */
 package org.apache.harmony.nio.tests.java.nio.channels;
 
-import java.io.IOException;
 import java.nio.channels.NoConnectionPendingException;
 
 import junit.framework.TestCase;
-import tests.util.SerializationTester;
+
+import org.apache.harmony.testframework.serialization.SerializationTest;
 
 /**
  * Tests for NoConnectionPendingException
@@ -28,21 +28,17 @@
     /**
      * @tests serialization/deserialization compatibility.
      */
-    public void test_serialization() throws IOException, ClassNotFoundException {
-        NoConnectionPendingException object = new NoConnectionPendingException();
-        NoConnectionPendingException deObject = (NoConnectionPendingException) SerializationTester
-                .getDeserilizedObject(object);
-        assertNotNull(deObject);
+    public void testSerializationSelf() throws Exception {
+
+        SerializationTest.verifySelf(new NoConnectionPendingException());
     }
 
     /**
      * @tests serialization/deserialization compatibility with RI.
      */
-    public void test_compatibilitySerialization() throws Exception {
-        NoConnectionPendingException object = new NoConnectionPendingException();
-        NoConnectionPendingException deObject = (NoConnectionPendingException) SerializationTester
-                .readObject(object,
-                        "serialization/java/nio/channels/NoConnectionPendingExceptionTest.golden.ser");
-        assertNotNull(deObject);
+    public void testSerializationCompatibility() throws Exception {
+
+        SerializationTest
+                .verifyGolden(this, new NoConnectionPendingException());
     }
 }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NonReadableChannelExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NonReadableChannelExceptionTest.java?view=diff&rev=443293&r1=443292&r2=443293
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NonReadableChannelExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NonReadableChannelExceptionTest.java Thu Sep 14 02:17:30 2006
@@ -14,11 +14,11 @@
  */
 package org.apache.harmony.nio.tests.java.nio.channels;
 
-import java.io.IOException;
 import java.nio.channels.NonReadableChannelException;
 
 import junit.framework.TestCase;
-import tests.util.SerializationTester;
+
+import org.apache.harmony.testframework.serialization.SerializationTest;
 
 /**
  * Tests for NonReadableChannelException
@@ -28,21 +28,16 @@
     /**
      * @tests serialization/deserialization compatibility.
      */
-    public void test_serialization() throws IOException, ClassNotFoundException {
-        NonReadableChannelException object = new NonReadableChannelException();
-        NonReadableChannelException deObject = (NonReadableChannelException) SerializationTester
-                .getDeserilizedObject(object);
-        assertNotNull(deObject);
+    public void testSerializationSelf() throws Exception {
+
+        SerializationTest.verifySelf(new NonReadableChannelException());
     }
 
     /**
      * @tests serialization/deserialization compatibility with RI.
      */
-    public void test_compatibilitySerialization() throws Exception {
-        NonReadableChannelException object = new NonReadableChannelException();
-        NonReadableChannelException deObject = (NonReadableChannelException) SerializationTester
-                .readObject(object,
-                        "serialization/java/nio/channels/NonReadableChannelExceptionTest.golden.ser");
-        assertNotNull(deObject);
+    public void testSerializationCompatibility() throws Exception {
+
+        SerializationTest.verifyGolden(this, new NonReadableChannelException());
     }
 }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NonWritableChannelExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NonWritableChannelExceptionTest.java?view=diff&rev=443293&r1=443292&r2=443293
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NonWritableChannelExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NonWritableChannelExceptionTest.java Thu Sep 14 02:17:30 2006
@@ -14,11 +14,11 @@
  */
 package org.apache.harmony.nio.tests.java.nio.channels;
 
-import java.io.IOException;
 import java.nio.channels.NonWritableChannelException;
 
 import junit.framework.TestCase;
-import tests.util.SerializationTester;
+
+import org.apache.harmony.testframework.serialization.SerializationTest;
 
 /**
  * Tests for NonWritableChannelException
@@ -28,21 +28,16 @@
     /**
      * @tests serialization/deserialization compatibility.
      */
-    public void test_serialization() throws IOException, ClassNotFoundException {
-        NonWritableChannelException object = new NonWritableChannelException();
-        NonWritableChannelException deObject = (NonWritableChannelException) SerializationTester
-                .getDeserilizedObject(object);
-        assertNotNull(deObject);
+    public void testSerializationSelf() throws Exception {
+
+        SerializationTest.verifySelf(new NonWritableChannelException());
     }
 
     /**
      * @tests serialization/deserialization compatibility with RI.
      */
-    public void test_compatibilitySerialization() throws Exception {
-        NonWritableChannelException object = new NonWritableChannelException();
-        NonWritableChannelException deObject = (NonWritableChannelException) SerializationTester
-                .readObject(object,
-                        "serialization/java/nio/channels/NonWritableChannelExceptionTest.golden.ser");
-        assertNotNull(deObject);
+    public void testSerializationCompatibility() throws Exception {
+
+        SerializationTest.verifyGolden(this, new NonWritableChannelException());
     }
 }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NotYetBoundExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NotYetBoundExceptionTest.java?view=diff&rev=443293&r1=443292&r2=443293
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NotYetBoundExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NotYetBoundExceptionTest.java Thu Sep 14 02:17:30 2006
@@ -14,11 +14,11 @@
  */
 package org.apache.harmony.nio.tests.java.nio.channels;
 
-import java.io.IOException;
 import java.nio.channels.NotYetBoundException;
 
 import junit.framework.TestCase;
-import tests.util.SerializationTester;
+
+import org.apache.harmony.testframework.serialization.SerializationTest;
 
 /**
  * Tests for NotYetBoundException
@@ -28,21 +28,16 @@
     /**
      * @tests serialization/deserialization compatibility.
      */
-    public void test_serialization() throws IOException, ClassNotFoundException {
-        NotYetBoundException object = new NotYetBoundException();
-        NotYetBoundException deObject = (NotYetBoundException) SerializationTester
-                .getDeserilizedObject(object);
-        assertNotNull(deObject);
+    public void testSerializationSelf() throws Exception {
+
+        SerializationTest.verifySelf(new NotYetBoundException());
     }
 
     /**
      * @tests serialization/deserialization compatibility with RI.
      */
-    public void test_compatibilitySerialization() throws Exception {
-        NotYetBoundException object = new NotYetBoundException();
-        NotYetBoundException deObject = (NotYetBoundException) SerializationTester
-                .readObject(object,
-                        "serialization/java/nio/channels/NotYetBoundExceptionTest.golden.ser");
-        assertNotNull(deObject);
+    public void testSerializationCompatibility() throws Exception {
+
+        SerializationTest.verifyGolden(this, new NotYetBoundException());
     }
 }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NotYetConnectedExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NotYetConnectedExceptionTest.java?view=diff&rev=443293&r1=443292&r2=443293
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NotYetConnectedExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/NotYetConnectedExceptionTest.java Thu Sep 14 02:17:30 2006
@@ -14,11 +14,11 @@
  */
 package org.apache.harmony.nio.tests.java.nio.channels;
 
-import java.io.IOException;
 import java.nio.channels.NotYetConnectedException;
 
 import junit.framework.TestCase;
-import tests.util.SerializationTester;
+
+import org.apache.harmony.testframework.serialization.SerializationTest;
 
 /**
  * Tests for NotYetConnectedException
@@ -28,21 +28,16 @@
     /**
      * @tests serialization/deserialization compatibility.
      */
-    public void test_serialization() throws IOException, ClassNotFoundException {
-        NotYetConnectedException object = new NotYetConnectedException();
-        NotYetConnectedException deObject = (NotYetConnectedException) SerializationTester
-                .getDeserilizedObject(object);
-        assertNotNull(deObject);
+    public void testSerializationSelf() throws Exception {
+
+        SerializationTest.verifySelf(new NotYetConnectedException());
     }
 
     /**
      * @tests serialization/deserialization compatibility with RI.
      */
-    public void test_compatibilitySerialization() throws Exception {
-        NotYetConnectedException object = new NotYetConnectedException();
-        NotYetConnectedException deObject = (NotYetConnectedException) SerializationTester
-                .readObject(object,
-                        "serialization/java/nio/channels/NotYetConnectedExceptionTest.golden.ser");
-        assertNotNull(deObject);
+    public void testSerializationCompatibility() throws Exception {
+
+        SerializationTest.verifyGolden(this, new NotYetConnectedException());
     }
 }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/OverlappingFileLockExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/OverlappingFileLockExceptionTest.java?view=diff&rev=443293&r1=443292&r2=443293
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/OverlappingFileLockExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/OverlappingFileLockExceptionTest.java Thu Sep 14 02:17:30 2006
@@ -14,11 +14,11 @@
  */
 package org.apache.harmony.nio.tests.java.nio.channels;
 
-import java.io.IOException;
 import java.nio.channels.OverlappingFileLockException;
 
 import junit.framework.TestCase;
-import tests.util.SerializationTester;
+
+import org.apache.harmony.testframework.serialization.SerializationTest;
 
 /**
  * Tests for OverlappingFileLockException
@@ -28,21 +28,17 @@
     /**
      * @tests serialization/deserialization compatibility.
      */
-    public void test_serialization() throws IOException, ClassNotFoundException {
-        OverlappingFileLockException object = new OverlappingFileLockException();
-        OverlappingFileLockException deObject = (OverlappingFileLockException) SerializationTester
-                .getDeserilizedObject(object);
-        assertNotNull(deObject);
+    public void testSerializationSelf() throws Exception {
+
+        SerializationTest.verifySelf(new OverlappingFileLockException());
     }
 
     /**
      * @tests serialization/deserialization compatibility with RI.
      */
-    public void test_compatibilitySerialization() throws Exception {
-        OverlappingFileLockException object = new OverlappingFileLockException();
-        OverlappingFileLockException deObject = (OverlappingFileLockException) SerializationTester
-                .readObject(object,
-                        "serialization/java/nio/channels/OverlappingFileLockExceptionTest.golden.ser");
-        assertNotNull(deObject);
+    public void testSerializationCompatibility() throws Exception {
+
+        SerializationTest
+                .verifyGolden(this, new OverlappingFileLockException());
     }
 }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/UnresolvedAddressExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/UnresolvedAddressExceptionTest.java?view=diff&rev=443293&r1=443292&r2=443293
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/UnresolvedAddressExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/UnresolvedAddressExceptionTest.java Thu Sep 14 02:17:30 2006
@@ -14,11 +14,11 @@
  */
 package org.apache.harmony.nio.tests.java.nio.channels;
 
-import java.io.IOException;
 import java.nio.channels.UnresolvedAddressException;
 
 import junit.framework.TestCase;
-import tests.util.SerializationTester;
+
+import org.apache.harmony.testframework.serialization.SerializationTest;
 
 /**
  * Tests for UnresolvedAddressException
@@ -28,21 +28,16 @@
     /**
      * @tests serialization/deserialization compatibility.
      */
-    public void test_serialization() throws IOException, ClassNotFoundException {
-        UnresolvedAddressException object = new UnresolvedAddressException();
-        UnresolvedAddressException deObject = (UnresolvedAddressException) SerializationTester
-                .getDeserilizedObject(object);
-        assertNotNull(deObject);
+    public void testSerializationSelf() throws Exception {
+
+        SerializationTest.verifySelf(new UnresolvedAddressException());
     }
 
     /**
      * @tests serialization/deserialization compatibility with RI.
      */
-    public void test_compatibilitySerialization() throws Exception {
-        UnresolvedAddressException object = new UnresolvedAddressException();
-        UnresolvedAddressException deObject = (UnresolvedAddressException) SerializationTester
-                .readObject(object,
-                        "serialization/java/nio/channels/UnresolvedAddressExceptionTest.golden.ser");
-        assertNotNull(deObject);
+    public void testSerializationCompatibility() throws Exception {
+
+        SerializationTest.verifyGolden(this, new UnresolvedAddressException());
     }
 }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/UnsupportedAddressTypeExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/UnsupportedAddressTypeExceptionTest.java?view=diff&rev=443293&r1=443292&r2=443293
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/UnsupportedAddressTypeExceptionTest.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/UnsupportedAddressTypeExceptionTest.java Thu Sep 14 02:17:30 2006
@@ -14,11 +14,11 @@
  */
 package org.apache.harmony.nio.tests.java.nio.channels;
 
-import java.io.IOException;
 import java.nio.channels.UnsupportedAddressTypeException;
 
 import junit.framework.TestCase;
-import tests.util.SerializationTester;
+
+import org.apache.harmony.testframework.serialization.SerializationTest;
 
 /**
  * Tests for UnsupportedAddressTypeException
@@ -28,22 +28,17 @@
     /**
      * @tests serialization/deserialization compatibility.
      */
-    public void test_serialization() throws IOException, ClassNotFoundException {
-        UnsupportedAddressTypeException object = new UnsupportedAddressTypeException();
-        UnsupportedAddressTypeException deObject = (UnsupportedAddressTypeException) SerializationTester
-                .getDeserilizedObject(object);
-        assertNotNull(deObject);
+    public void testSerializationSelf() throws Exception {
+
+        SerializationTest.verifySelf(new UnsupportedAddressTypeException());
     }
 
     /**
      * @tests serialization/deserialization compatibility with RI.
      */
-    public void test_compatibilitySerialization() throws Exception {
-        UnsupportedAddressTypeException object = new UnsupportedAddressTypeException();
-        UnsupportedAddressTypeException deObject = (UnsupportedAddressTypeException) SerializationTester
-                .readObject(
-                        object,
-                        "serialization/java/nio/channels/UnsupportedAddressTypeExceptionTest.golden.ser");
-        assertNotNull(deObject);
+    public void testSerializationCompatibility() throws Exception {
+
+        SerializationTest.verifyGolden(this,
+                new UnsupportedAddressTypeException());
     }
 }



Mime
View raw message