commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bode...@apache.org
Subject svn commit: r745046 - in /commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip: AsiExtraFieldTest.java ExtraFieldUtilsTest.java ZipArchiveEntryTest.java ZipArchiveOutputStreamTest.java ZipLongTest.java ZipShortTest.java
Date Tue, 17 Feb 2009 13:30:23 GMT
Author: bodewig
Date: Tue Feb 17 13:30:20 2009
New Revision: 745046

URL: http://svn.apache.org/viewvc?rev=745046&view=rev
Log:
copy Ant's zip tests

Added:
    commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/AsiExtraFieldTest.java
      - copied, changed from r745042, ant/core/trunk/src/tests/junit/org/apache/tools/zip/AsiExtraFieldTest.java
    commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ExtraFieldUtilsTest.java
      - copied, changed from r745042, ant/core/trunk/src/tests/junit/org/apache/tools/zip/ExtraFieldUtilsTest.java
    commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ZipArchiveEntryTest.java
      - copied, changed from r745042, ant/core/trunk/src/tests/junit/org/apache/tools/zip/ZipEntryTest.java
    commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ZipArchiveOutputStreamTest.java
      - copied, changed from r745042, ant/core/trunk/src/tests/junit/org/apache/tools/zip/ZipOutputStreamTest.java
    commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ZipLongTest.java
      - copied, changed from r745042, ant/core/trunk/src/tests/junit/org/apache/tools/zip/ZipLongTest.java
    commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ZipShortTest.java
      - copied, changed from r745042, ant/core/trunk/src/tests/junit/org/apache/tools/zip/ZipShortTest.java

Copied: commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/AsiExtraFieldTest.java
(from r745042, ant/core/trunk/src/tests/junit/org/apache/tools/zip/AsiExtraFieldTest.java)
URL: http://svn.apache.org/viewvc/commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/AsiExtraFieldTest.java?p2=commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/AsiExtraFieldTest.java&p1=ant/core/trunk/src/tests/junit/org/apache/tools/zip/AsiExtraFieldTest.java&r1=745042&r2=745046&rev=745046&view=diff
==============================================================================
--- ant/core/trunk/src/tests/junit/org/apache/tools/zip/AsiExtraFieldTest.java (original)
+++ commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/AsiExtraFieldTest.java
Tue Feb 17 13:30:20 2009
@@ -16,12 +16,12 @@
  *
  */
 
-package org.apache.tools.zip;
+package org.apache.commons.compress.archivers.zip;
 
 import junit.framework.TestCase;
 
 /**
- * JUnit 3 testcases for org.apache.tools.zip.AsiExtraField.
+ * JUnit 3 testcases for org.apache.commons.compress.archivers.zip.AsiExtraField.
  *
  */
 public class AsiExtraFieldTest extends TestCase implements UnixStat {

Copied: commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ExtraFieldUtilsTest.java
(from r745042, ant/core/trunk/src/tests/junit/org/apache/tools/zip/ExtraFieldUtilsTest.java)
URL: http://svn.apache.org/viewvc/commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ExtraFieldUtilsTest.java?p2=commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ExtraFieldUtilsTest.java&p1=ant/core/trunk/src/tests/junit/org/apache/tools/zip/ExtraFieldUtilsTest.java&r1=745042&r2=745046&rev=745046&view=diff
==============================================================================
--- ant/core/trunk/src/tests/junit/org/apache/tools/zip/ExtraFieldUtilsTest.java (original)
+++ commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ExtraFieldUtilsTest.java
Tue Feb 17 13:30:20 2009
@@ -16,12 +16,12 @@
  *
  */
 
-package org.apache.tools.zip;
+package org.apache.commons.compress.archivers.zip;
 
 import junit.framework.TestCase;
 
 /**
- * JUnit 3 testcases for org.apache.tools.zip.ExtraFieldUtils.
+ * JUnit 3 testcases for org.apache.commons.compress.archivers.zip.ExtraFieldUtils.
  *
  */
 public class ExtraFieldUtilsTest extends TestCase implements UnixStat {

Copied: commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ZipArchiveEntryTest.java
(from r745042, ant/core/trunk/src/tests/junit/org/apache/tools/zip/ZipEntryTest.java)
URL: http://svn.apache.org/viewvc/commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ZipArchiveEntryTest.java?p2=commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ZipArchiveEntryTest.java&p1=ant/core/trunk/src/tests/junit/org/apache/tools/zip/ZipEntryTest.java&r1=745042&r2=745046&rev=745046&view=diff
==============================================================================
--- ant/core/trunk/src/tests/junit/org/apache/tools/zip/ZipEntryTest.java (original)
+++ commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ZipArchiveEntryTest.java
Tue Feb 17 13:30:20 2009
@@ -16,17 +16,17 @@
  *
  */
 
-package org.apache.tools.zip;
+package org.apache.commons.compress.archivers.zip;
 
 import junit.framework.TestCase;
 
 /**
- * JUnit 3 testcases for org.apache.tools.zip.ZipEntry.
+ * JUnit 3 testcases for org.apache.commons.compress.archivers.zip.ZipEntry.
  *
  */
-public class ZipEntryTest extends TestCase {
+public class ZipArchiveEntryTest extends TestCase {
 
-    public ZipEntryTest(String name) {
+    public ZipArchiveEntryTest(String name) {
         super(name);
     }
 
@@ -43,7 +43,7 @@
         u.setHeaderId(new ZipShort(1));
         u.setLocalFileDataData(new byte[0]);
 
-        ZipEntry ze = new ZipEntry("test/");
+        ZipArchiveEntry ze = new ZipArchiveEntry("test/");
         ze.setExtraFields(new ZipExtraField[] {a, u});
         byte[] data1 = ze.getExtra();
         ZipExtraField[] result = ze.getExtraFields();
@@ -86,7 +86,7 @@
     }
 
     public void testUnixMode() {
-        ZipEntry ze = new ZipEntry("foo");
+        ZipArchiveEntry ze = new ZipArchiveEntry("foo");
         assertEquals(0, ze.getPlatform());
         ze.setUnixMode(0755);
         assertEquals(3, ze.getPlatform());
@@ -100,7 +100,7 @@
                      (ze.getExternalAttributes() >> 16) & 0xFFFF);
         assertEquals(1, ze.getExternalAttributes()  & 0xFFFF);
 
-        ze = new ZipEntry("foo/");
+        ze = new ZipArchiveEntry("foo/");
         assertEquals(0, ze.getPlatform());
         ze.setUnixMode(0777);
         assertEquals(3, ze.getPlatform());

Copied: commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ZipArchiveOutputStreamTest.java
(from r745042, ant/core/trunk/src/tests/junit/org/apache/tools/zip/ZipOutputStreamTest.java)
URL: http://svn.apache.org/viewvc/commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ZipArchiveOutputStreamTest.java?p2=commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ZipArchiveOutputStreamTest.java&p1=ant/core/trunk/src/tests/junit/org/apache/tools/zip/ZipOutputStreamTest.java&r1=745042&r2=745046&rev=745046&view=diff
==============================================================================
--- ant/core/trunk/src/tests/junit/org/apache/tools/zip/ZipOutputStreamTest.java (original)
+++ commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ZipArchiveOutputStreamTest.java
Tue Feb 17 13:30:20 2009
@@ -16,14 +16,14 @@
  *
  */
 
-package org.apache.tools.zip;
+package org.apache.commons.compress.archivers.zip;
 
 import java.util.Calendar;
 import java.util.Date;
 
 import junit.framework.TestCase;
 
-public class ZipOutputStreamTest extends TestCase {
+public class ZipArchiveOutputStreamTest extends TestCase {
     
     private Date time;
     private ZipLong zl;
@@ -31,7 +31,7 @@
     /**
      * Constructor
      */	
-    public ZipOutputStreamTest(String name) {
+    public ZipArchiveOutputStreamTest(String name) {
         super(name);
     }
 	
@@ -61,17 +61,17 @@
     }
     
     public void testZipLong() throws Exception {
-        ZipLong test = ZipOutputStream.toDosTime(time);
+        ZipLong test = ZipArchiveOutputStream.toDosTime(time);
         assertEquals(test.getValue(), zl.getValue());
     }
 
     public void testAdjustToLong() {
         assertEquals((long) Integer.MAX_VALUE,
-                     ZipOutputStream.adjustToLong(Integer.MAX_VALUE));
+                     ZipArchiveOutputStream.adjustToLong(Integer.MAX_VALUE));
         assertEquals(((long) Integer.MAX_VALUE) + 1,
-                     ZipOutputStream.adjustToLong(Integer.MAX_VALUE + 1));
+                     ZipArchiveOutputStream.adjustToLong(Integer.MAX_VALUE + 1));
         assertEquals(2 * ((long) Integer.MAX_VALUE),
-                     ZipOutputStream.adjustToLong(2 * Integer.MAX_VALUE));
+                     ZipArchiveOutputStream.adjustToLong(2 * Integer.MAX_VALUE));
     }
 
 }

Copied: commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ZipLongTest.java
(from r745042, ant/core/trunk/src/tests/junit/org/apache/tools/zip/ZipLongTest.java)
URL: http://svn.apache.org/viewvc/commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ZipLongTest.java?p2=commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ZipLongTest.java&p1=ant/core/trunk/src/tests/junit/org/apache/tools/zip/ZipLongTest.java&r1=745042&r2=745046&rev=745046&view=diff
==============================================================================
--- ant/core/trunk/src/tests/junit/org/apache/tools/zip/ZipLongTest.java (original)
+++ commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ZipLongTest.java
Tue Feb 17 13:30:20 2009
@@ -16,12 +16,12 @@
  *
  */
 
-package org.apache.tools.zip;
+package org.apache.commons.compress.archivers.zip;
 
 import junit.framework.TestCase;
 
 /**
- * JUnit 3 testcases for org.apache.tools.zip.ZipLong.
+ * JUnit 3 testcases for org.apache.commons.compress.archivers.zip.ZipLong.
  *
  */
 public class ZipLongTest extends TestCase {

Copied: commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ZipShortTest.java
(from r745042, ant/core/trunk/src/tests/junit/org/apache/tools/zip/ZipShortTest.java)
URL: http://svn.apache.org/viewvc/commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ZipShortTest.java?p2=commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ZipShortTest.java&p1=ant/core/trunk/src/tests/junit/org/apache/tools/zip/ZipShortTest.java&r1=745042&r2=745046&rev=745046&view=diff
==============================================================================
--- ant/core/trunk/src/tests/junit/org/apache/tools/zip/ZipShortTest.java (original)
+++ commons/sandbox/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/ZipShortTest.java
Tue Feb 17 13:30:20 2009
@@ -16,12 +16,12 @@
  *
  */
 
-package org.apache.tools.zip;
+package org.apache.commons.compress.archivers.zip;
 
 import junit.framework.TestCase;
 
 /**
- * JUnit 3 testcases for org.apache.tools.zip.ZipShort.
+ * JUnit 3 testcases for org.apache.commons.compress.archivers.zip.ZipShort.
  *
  */
 public class ZipShortTest extends TestCase {



Mime
View raw message