sis-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From desruisse...@apache.org
Subject svn commit: r1444607 - in /sis/branches/JDK7/sis-utility/src: main/java/org/apache/sis/measure/Range.java test/java/org/apache/sis/measure/RangeTest.java
Date Sun, 10 Feb 2013 20:41:12 GMT
Author: desruisseaux
Date: Sun Feb 10 20:41:12 2013
New Revision: 1444607

URL: http://svn.apache.org/r1444607
Log:
Added serialization test.

Modified:
    sis/branches/JDK7/sis-utility/src/main/java/org/apache/sis/measure/Range.java
    sis/branches/JDK7/sis-utility/src/test/java/org/apache/sis/measure/RangeTest.java

Modified: sis/branches/JDK7/sis-utility/src/main/java/org/apache/sis/measure/Range.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/sis-utility/src/main/java/org/apache/sis/measure/Range.java?rev=1444607&r1=1444606&r2=1444607&view=diff
==============================================================================
--- sis/branches/JDK7/sis-utility/src/main/java/org/apache/sis/measure/Range.java (original)
+++ sis/branches/JDK7/sis-utility/src/main/java/org/apache/sis/measure/Range.java Sun Feb
10 20:41:12 2013
@@ -76,7 +76,7 @@ public class Range<T extends Comparable<
      *
      * @see #getElementType()
      */
-    private final Class<T> elementType;
+    final Class<T> elementType;
 
     /**
      * The minimal and maximal values.

Modified: sis/branches/JDK7/sis-utility/src/test/java/org/apache/sis/measure/RangeTest.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/sis-utility/src/test/java/org/apache/sis/measure/RangeTest.java?rev=1444607&r1=1444606&r2=1444607&view=diff
==============================================================================
--- sis/branches/JDK7/sis-utility/src/test/java/org/apache/sis/measure/RangeTest.java (original)
+++ sis/branches/JDK7/sis-utility/src/test/java/org/apache/sis/measure/RangeTest.java Sun
Feb 10 20:41:12 2013
@@ -19,7 +19,7 @@ package org.apache.sis.measure;
 import org.apache.sis.test.TestCase;
 import org.junit.Test;
 
-import static org.junit.Assert.*;
+import static org.apache.sis.test.Assert.*;
 
 
 /**
@@ -326,4 +326,13 @@ public final strictfp class RangeTest ex
         assertTrue(range6.isEmpty());
         assertTrue(range5.equals(range6));
     }
+
+    /**
+     * Tests serialization.
+     */
+    @Test
+    public void testSerialization() {
+        final Range<Integer> range  = new Range<>(Integer.class, -10, 10);
+        assertNotSame(range, assertSerializedEquals(range));
+    }
 }



Mime
View raw message