harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sjanu...@apache.org
Subject svn commit: r748098 - /harmony/enhanced/classlib/trunk/modules/pack200/src/test/java/org/apache/harmony/pack200/tests/ArchiveTest.java
Date Thu, 26 Feb 2009 11:33:49 GMT
Author: sjanuary
Date: Thu Feb 26 11:33:49 2009
New Revision: 748098

URL: http://svn.apache.org/viewvc?rev=748098&view=rev
Log:
Pack200 - update segment limit test

Modified:
    harmony/enhanced/classlib/trunk/modules/pack200/src/test/java/org/apache/harmony/pack200/tests/ArchiveTest.java

Modified: harmony/enhanced/classlib/trunk/modules/pack200/src/test/java/org/apache/harmony/pack200/tests/ArchiveTest.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/pack200/src/test/java/org/apache/harmony/pack200/tests/ArchiveTest.java?rev=748098&r1=748097&r2=748098&view=diff
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/pack200/src/test/java/org/apache/harmony/pack200/tests/ArchiveTest.java
(original)
+++ harmony/enhanced/classlib/trunk/modules/pack200/src/test/java/org/apache/harmony/pack200/tests/ArchiveTest.java
Thu Feb 26 11:33:49 2009
@@ -145,28 +145,13 @@
     }
 
     public void testSegmentLimits() throws IOException, Pack200Exception {
-        in = new JarInputStream(
-                Archive.class
-                        .getResourceAsStream("/org/apache/harmony/pack200/tests/hw.jar"));
-        file = File.createTempFile("helloworld", ".pack.gz");
-        out = new FileOutputStream(file);
-        Archive archive = new Archive(in, out, true);
-        archive.setSegmentLimit(1);
-        try {
-            archive.pack();
-            fail("Should throw an execption with a 1-byte segment limit");
-        } catch (Pack200Exception pe) {
-            assertEquals("Expected limit too small message", "Segment limit is too small
for the files you are trying to pack", pe.getMessage());
-        }
-        in.close();
-        out.close();
 
         in = new JarInputStream(
                 Archive.class
                         .getResourceAsStream("/org/apache/harmony/pack200/tests/hw.jar"));
         file = File.createTempFile("helloworld", ".pack.gz");
         out = new FileOutputStream(file);
-        archive = new Archive(in, out, true);
+        Archive archive = new Archive(in, out, true);
         archive.setSegmentLimit(0);
         archive.pack();
         in.close();



Mime
View raw message