harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ghar...@apache.org
Subject svn commit: r405059 - in /incubator/harmony/enhanced/classlib/trunk/modules/luni/src/test: java/org/apache/harmony/tests/java/lang/ resources/serialization/java/lang/
Date Mon, 08 May 2006 14:10:41 GMT
Author: gharley
Date: Mon May  8 07:10:39 2006
New Revision: 405059

URL: http://svn.apache.org/viewcvs?rev=405059&view=rev
Log:
HARMONY 445 : StringBuffer and StringBuilder serialization tests

Added:
    incubator/harmony/enhanced/classlib/trunk/modules/luni/src/test/resources/serialization/java/lang/StringBuffer.ser
  (with props)
    incubator/harmony/enhanced/classlib/trunk/modules/luni/src/test/resources/serialization/java/lang/StringBuilder.ser
  (with props)
Modified:
    incubator/harmony/enhanced/classlib/trunk/modules/luni/src/test/java/org/apache/harmony/tests/java/lang/StringBufferTest.java
    incubator/harmony/enhanced/classlib/trunk/modules/luni/src/test/java/org/apache/harmony/tests/java/lang/StringBuilderTest.java

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/test/java/org/apache/harmony/tests/java/lang/StringBufferTest.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/test/java/org/apache/harmony/tests/java/lang/StringBufferTest.java?rev=405059&r1=405058&r2=405059&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/test/java/org/apache/harmony/tests/java/lang/StringBufferTest.java
(original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/test/java/org/apache/harmony/tests/java/lang/StringBufferTest.java
Mon May  8 07:10:39 2006
@@ -15,6 +15,7 @@
 
 package org.apache.harmony.tests.java.lang;
 
+import tests.util.SerializationTester;
 import junit.framework.TestCase;
 
 public class StringBufferTest extends TestCase {
@@ -396,5 +397,18 @@
         } catch (IndexOutOfBoundsException e) {
             
         }
+    }
+    
+    public void test_serialization() throws Exception {
+        final String fixture = "0123456789";
+        StringBuffer sb = new StringBuffer(fixture);
+        SerializationTester.assertEquals(sb);
+    }
+
+    public void test_serializationCompatability() throws Exception {
+        final String fixture = "0123456789";
+        StringBuffer sb = new StringBuffer(fixture);
+        SerializationTester.assertCompabilityEquals(sb,
+                "serialization/java/lang/StringBuffer.ser");
     }
 }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/test/java/org/apache/harmony/tests/java/lang/StringBuilderTest.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/test/java/org/apache/harmony/tests/java/lang/StringBuilderTest.java?rev=405059&r1=405058&r2=405059&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/test/java/org/apache/harmony/tests/java/lang/StringBuilderTest.java
(original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/test/java/org/apache/harmony/tests/java/lang/StringBuilderTest.java
Mon May  8 07:10:39 2006
@@ -19,6 +19,8 @@
 
 import java.util.Arrays;
 
+import tests.util.SerializationTester;
+
 import junit.framework.TestCase;
 
 public class StringBuilderTest extends TestCase {
@@ -1756,6 +1758,19 @@
 		assertEquals(fixture.length(), sb.length());
 		assertEquals(fixture, sb.toString());
 	}
+    
+    public void test_serialization() throws Exception {
+        final String fixture = "0123456789";
+        StringBuilder sb = new StringBuilder(fixture);
+        SerializationTester.assertEquals(sb);
+    }
+
+    public void test_serializationCompatability() throws Exception {
+        final String fixture = "0123456789";
+        StringBuilder sb = new StringBuilder(fixture);
+        SerializationTester.assertCompabilityEquals(sb,
+                "serialization/java/lang/StringBuilder.ser");
+    }
 
 	private static final class Fixture {
 		static final Fixture INSTANCE = new Fixture();

Added: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/test/resources/serialization/java/lang/StringBuffer.ser
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/test/resources/serialization/java/lang/StringBuffer.ser?rev=405059&view=auto
==============================================================================
Binary file - no diff available.

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/test/resources/serialization/java/lang/StringBuffer.ser
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/test/resources/serialization/java/lang/StringBuilder.ser
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/test/resources/serialization/java/lang/StringBuilder.ser?rev=405059&view=auto
==============================================================================
Binary file - no diff available.

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/test/resources/serialization/java/lang/StringBuilder.ser
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream



Mime
View raw message