commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject svn commit: r1357025 - /commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/IOMethodsTest.java
Date Wed, 04 Jul 2012 00:33:28 GMT
Author: sebb
Date: Wed Jul  4 00:33:28 2012
New Revision: 1357025

URL: http://svn.apache.org/viewvc?rev=1357025&view=rev
Log:
Add explicit length checks

Modified:
    commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/IOMethodsTest.java

Modified: commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/IOMethodsTest.java
URL: http://svn.apache.org/viewvc/commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/IOMethodsTest.java?rev=1357025&r1=1357024&r2=1357025&view=diff
==============================================================================
--- commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/IOMethodsTest.java
(original)
+++ commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/IOMethodsTest.java
Wed Jul  4 00:33:28 2012
@@ -114,6 +114,10 @@ public class IOMethodsTest extends Abstr
         aos3.write(byteTest, 0, byteTest.length);
         aos3.closeArchiveEntry();
         aos3.close();
+        assertEquals("aos1Bytes!=aos2Bytes",aos1.getBytesWritten(),aos2.getBytesWritten());
+        assertEquals("aos1Bytes!=aos3Bytes",aos1.getBytesWritten(),aos3.getBytesWritten());
+        assertEquals("out1Len!=out2Len",out1.toString().length(),out2.toString().length());
+        assertEquals("out1Len!=out2Len",out1.toString().length(),out3.toString().length());
         assertEquals("out1!=out2",out1.toString(),out2.toString());
         assertEquals("out1!=out3",out1.toString(),out3.toString());
     }
@@ -165,6 +169,8 @@ public class IOMethodsTest extends Abstr
         }
         ais3.close();
 
+        assertEquals("out1Len!=out2Len",out1.toString().length(),out2.toString().length());
+        assertEquals("out1Len!=out3Len",out1.toString().length(),out3.toString().length());
         assertEquals("out1!=out2",out1.toString(),out2.toString());
         assertEquals("out1!=out3",out1.toString(),out3.toString());
     }



Mime
View raw message