harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mloe...@apache.org
Subject svn commit: r417712 - in /incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test: java/org/apache/harmony/tests/java/nio/channels/ resources/serialization/java/nio/channels/
Date Wed, 28 Jun 2006 10:16:01 GMT
Author: mloenko
Date: Wed Jun 28 03:16:00 2006
New Revision: 417712

URL: http://svn.apache.org/viewvc?rev=417712&view=rev
Log:
applied patch from HARMONY-687
[classlib][nio] Tests for java.nio.channels.AsynchronousCloseException are missing

Added:
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/org/apache/harmony/tests/java/nio/channels/AsynchronousCloseExceptionTest.java
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/AsynchronousCloseExceptionTest.golden.ser
  (with props)
Modified:
    incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/org/apache/harmony/tests/java/nio/channels/AllTests.java

Modified: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/org/apache/harmony/tests/java/nio/channels/AllTests.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/org/apache/harmony/tests/java/nio/channels/AllTests.java?rev=417712&r1=417711&r2=417712&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/org/apache/harmony/tests/java/nio/channels/AllTests.java
(original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/org/apache/harmony/tests/java/nio/channels/AllTests.java
Wed Jun 28 03:16:00 2006
@@ -38,6 +38,7 @@
         suite.addTestSuite(AlreadyConnectedExceptionTest.class);
         suite.addTestSuite(SelectableChannelTest.class);
         suite.addTestSuite(FileLockTest.class);
+        suite.addTestSuite(AsynchronousCloseExceptionTest.class);
         //$JUnit-END$
         return suite;
     }

Added: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/org/apache/harmony/tests/java/nio/channels/AsynchronousCloseExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/org/apache/harmony/tests/java/nio/channels/AsynchronousCloseExceptionTest.java?rev=417712&view=auto
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/org/apache/harmony/tests/java/nio/channels/AsynchronousCloseExceptionTest.java
(added)
+++ incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/java/org/apache/harmony/tests/java/nio/channels/AsynchronousCloseExceptionTest.java
Wed Jun 28 03:16:00 2006
@@ -0,0 +1,48 @@
+/* Copyright 2006 The Apache Software Foundation or its licensors, as applicable
+ * 
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * 
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.harmony.tests.java.nio.channels;
+
+import java.io.IOException;
+import java.nio.channels.AsynchronousCloseException;
+
+import junit.framework.TestCase;
+import tests.util.SerializationTester;
+
+/**
+ * Tests for AsynchronousCloseException
+ */
+public class AsynchronousCloseExceptionTest extends TestCase {
+
+    /**
+     * @tests serialization/deserialization compatibility.
+     */
+    public void test_serialization() throws IOException, ClassNotFoundException {
+        AsynchronousCloseException object = new AsynchronousCloseException();
+        AsynchronousCloseException deObject = (AsynchronousCloseException) SerializationTester
+                .getDeserilizedObject(object);
+        assertNotNull(deObject);
+    }
+
+    /**
+     * @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);
+    }
+}

Added: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/AsynchronousCloseExceptionTest.golden.ser
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/AsynchronousCloseExceptionTest.golden.ser?rev=417712&view=auto
==============================================================================
Binary file - no diff available.

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/nio/src/test/resources/serialization/java/nio/channels/AsynchronousCloseExceptionTest.golden.ser
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream



Mime
View raw message