commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From krosenv...@apache.org
Subject svn commit: r1650766 - in /commons/proper/compress/trunk/src: main/java/org/apache/commons/compress/archivers/dump/ main/java/org/apache/commons/compress/archivers/sevenz/ main/java/org/apache/commons/compress/archivers/tar/ main/java/org/apache/common...
Date Sat, 10 Jan 2015 16:15:55 GMT
Author: krosenvold
Date: Sat Jan 10 16:15:54 2015
New Revision: 1650766

URL: http://svn.apache.org/r1650766
Log:
Fixed style issues as reported by IntelliJ

Modified:
    commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/dump/Dirent.java
    commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/dump/DumpArchiveInputStream.java
    commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/CLI.java
    commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/DeltaDecoder.java
    commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/LZMA2Decoder.java
    commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/SevenZFile.java
    commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/SevenZOutputFile.java
    commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/TarArchiveEntry.java
    commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/TarUtils.java
    commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ParallelScatterZipCreator.java
    commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ZipArchiveOutputStream.java
    commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ZipMethod.java
    commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/compressors/z/ZCompressorInputStream.java
    commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/AbstractTestCase.java
    commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/archivers/LongPathTest.java
    commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/UTF8ZipFilesTest.java
    commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/compressors/snappy/FramedSnappyCompressorInputStreamTest.java

Modified: commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/dump/Dirent.java
URL: http://svn.apache.org/viewvc/commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/dump/Dirent.java?rev=1650766&r1=1650765&r2=1650766&view=diff
==============================================================================
--- commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/dump/Dirent.java
(original)
+++ commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/dump/Dirent.java
Sat Jan 10 16:15:54 2015
@@ -79,6 +79,6 @@ class Dirent {
      */
     @Override
     public String toString() {
-        return String.format("[%d]: %s", Integer.valueOf(ino), name);
+        return String.format("[%d]: %s", ino, name);
     }
 }

Modified: commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/dump/DumpArchiveInputStream.java
URL: http://svn.apache.org/viewvc/commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/dump/DumpArchiveInputStream.java?rev=1650766&r1=1650765&r2=1650766&view=diff
==============================================================================
--- commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/dump/DumpArchiveInputStream.java
(original)
+++ commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/dump/DumpArchiveInputStream.java
Sat Jan 10 16:15:54 2015
@@ -127,7 +127,7 @@ public class DumpArchiveInputStream exte
 
         // put in a dummy record for the root node.
         Dirent root = new Dirent(2, 2, 4, ".");
-        names.put(Integer.valueOf(2), root);
+        names.put(2, root);
 
         // use priority based on queue to ensure parent directories are
         // released first.
@@ -306,7 +306,7 @@ public class DumpArchiveInputStream exte
         }
 
         entry.setName(path);
-        entry.setSimpleName(names.get(Integer.valueOf(entry.getIno())).getName());
+        entry.setSimpleName(names.get(entry.getIno()).getName());
         entry.setOffset(filepos);
 
         return entry;
@@ -327,9 +327,9 @@ public class DumpArchiveInputStream exte
                 raw.readRecord();
             }
 
-            if (!names.containsKey(Integer.valueOf(entry.getIno())) &&
+            if (!names.containsKey(entry.getIno()) &&
                     DumpArchiveConstants.SEGMENT_TYPE.INODE == entry.getHeaderType()) {
-                pending.put(Integer.valueOf(entry.getIno()), entry);
+                pending.put(entry.getIno(), entry);
             }
 
             int datalen = DumpArchiveConstants.TP_SIZE * entry.getHeaderCount();
@@ -367,7 +367,7 @@ public class DumpArchiveInputStream exte
                 }
                 */
 
-                names.put(Integer.valueOf(ino), d);
+                names.put(ino, d);
 
                 // check whether this allows us to fill anything in the pending list.
                 for (Map.Entry<Integer, DumpArchiveEntry> e : pending.entrySet()) {
@@ -384,7 +384,7 @@ public class DumpArchiveInputStream exte
                 // remove anything that we found. (We can't do it earlier
                 // because of concurrent modification exceptions.)
                 for (DumpArchiveEntry e : queue) {
-                    pending.remove(Integer.valueOf(e.getIno()));
+                    pending.remove(e.getIno());
                 }
             }
 
@@ -413,12 +413,12 @@ public class DumpArchiveInputStream exte
         Dirent dirent = null;
 
         for (int i = entry.getIno();; i = dirent.getParentIno()) {
-            if (!names.containsKey(Integer.valueOf(i))) {
+            if (!names.containsKey(i)) {
                 elements.clear();
                 break;
             }
 
-            dirent = names.get(Integer.valueOf(i));
+            dirent = names.get(i);
             elements.push(dirent.getName());
 
             if (dirent.getIno() == dirent.getParentIno()) {
@@ -428,7 +428,7 @@ public class DumpArchiveInputStream exte
 
         // if an element is missing defer the work and read next entry.
         if (elements.isEmpty()) {
-            pending.put(Integer.valueOf(entry.getIno()), entry);
+            pending.put(entry.getIno(), entry);
 
             return null;
         }

Modified: commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/CLI.java
URL: http://svn.apache.org/viewvc/commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/CLI.java?rev=1650766&r1=1650765&r2=1650766&view=diff
==============================================================================
--- commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/CLI.java
(original)
+++ commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/CLI.java
Sat Jan 10 16:15:54 2015
@@ -58,7 +58,7 @@ public class CLI {
                     first = false;
                     sb.append(m.getMethod());
                     if (m.getOptions() != null) {
-                        sb.append("(" + m.getOptions() + ")");
+                        sb.append("(").append(m.getOptions()).append(")");
                     }
                 }
                 return sb.toString();

Modified: commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/DeltaDecoder.java
URL: http://svn.apache.org/viewvc/commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/DeltaDecoder.java?rev=1650766&r1=1650765&r2=1650766&view=diff
==============================================================================
--- commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/DeltaDecoder.java
(original)
+++ commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/DeltaDecoder.java
Sat Jan 10 16:15:54 2015
@@ -54,7 +54,7 @@ class DeltaDecoder extends CoderBase {
 
     @Override
     Object getOptionsFromCoder(Coder coder, InputStream in) {
-        return Integer.valueOf(getOptionsFromCoder(coder));
+        return getOptionsFromCoder(coder);
     }
 
     private int getOptionsFromCoder(Coder coder) {

Modified: commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/LZMA2Decoder.java
URL: http://svn.apache.org/viewvc/commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/LZMA2Decoder.java?rev=1650766&r1=1650765&r2=1650766&view=diff
==============================================================================
--- commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/LZMA2Decoder.java
(original)
+++ commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/LZMA2Decoder.java
Sat Jan 10 16:15:54 2015
@@ -62,7 +62,7 @@ class LZMA2Decoder extends CoderBase {
 
     @Override
     Object getOptionsFromCoder(Coder coder, InputStream in) {
-        return Integer.valueOf(getDictionarySize(coder));
+        return getDictionarySize(coder);
     }
 
     private int getDictSize(Object opts) {

Modified: commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/SevenZFile.java
URL: http://svn.apache.org/viewvc/commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/SevenZFile.java?rev=1650766&r1=1650765&r2=1650766&view=diff
==============================================================================
--- commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/SevenZFile.java
(original)
+++ commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/SevenZFile.java
Sat Jan 10 16:15:54 2015
@@ -163,7 +163,7 @@ public class SevenZFile implements Close
         final byte archiveVersionMinor = file.readByte();
         if (archiveVersionMajor != 0) {
             throw new IOException(String.format("Unsupported 7z version (%d,%d)",
-                    Byte.valueOf(archiveVersionMajor), Byte.valueOf(archiveVersionMinor)));
+                    archiveVersionMajor, archiveVersionMinor));
         }
 
         final long startHeaderCrc = 0xffffFFFFL & Integer.reverseBytes(file.readInt());

Modified: commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/SevenZOutputFile.java
URL: http://svn.apache.org/viewvc/commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/SevenZOutputFile.java?rev=1650766&r1=1650765&r2=1650766&view=diff
==============================================================================
--- commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/SevenZOutputFile.java
(original)
+++ commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/sevenz/SevenZOutputFile.java
Sat Jan 10 16:15:54 2015
@@ -490,9 +490,9 @@ public class SevenZOutputFile implements
         boolean hasEmptyFiles = false;
         int emptyStreamCounter = 0;
         final BitSet emptyFiles = new BitSet(0);
-        for (int i = 0; i < files.size(); i++) {
-            if (!files.get(i).hasStream()) {
-                boolean isDir = files.get(i).isDirectory();
+        for (SevenZArchiveEntry file1 : files) {
+            if (!file1.hasStream()) {
+                boolean isDir = file1.isDirectory();
                 emptyFiles.set(emptyStreamCounter++, !isDir);
                 hasEmptyFiles |= !isDir;
             }
@@ -513,9 +513,9 @@ public class SevenZOutputFile implements
         boolean hasAntiItems = false;
         final BitSet antiItems = new BitSet(0);
         int antiItemCounter = 0;
-        for (int i = 0; i < files.size(); i++) {
-            if (!files.get(i).hasStream()) {
-                boolean isAnti = files.get(i).isAntiItem();
+        for (SevenZArchiveEntry file1 : files) {
+            if (!file1.hasStream()) {
+                boolean isAnti = file1.isAntiItem();
                 antiItems.set(antiItemCounter++, isAnti);
                 hasAntiItems |= isAnti;
             }

Modified: commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/TarArchiveEntry.java
URL: http://svn.apache.org/viewvc/commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/TarArchiveEntry.java?rev=1650766&r1=1650765&r2=1650766&view=diff
==============================================================================
--- commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/TarArchiveEntry.java
(original)
+++ commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/TarArchiveEntry.java
Sat Jan 10 16:15:54 2015
@@ -378,7 +378,7 @@ public class TarArchiveEntry implements
      * @return This entry's name.
      */
     public String getName() {
-        return name.toString();
+        return name;
     }
 
     /**
@@ -405,7 +405,7 @@ public class TarArchiveEntry implements
      * @return This entry's link name.
      */
     public String getLinkName() {
-        return linkName.toString();
+        return linkName;
     }
 
     /**
@@ -461,7 +461,7 @@ public class TarArchiveEntry implements
      * @return This entry's user name.
      */
     public String getUserName() {
-        return userName.toString();
+        return userName;
     }
 
     /**
@@ -479,7 +479,7 @@ public class TarArchiveEntry implements
      * @return This entry's group name.
      */
     public String getGroupName() {
-        return groupName.toString();
+        return groupName;
     }
 
     /**
@@ -1035,7 +1035,7 @@ public class TarArchiveEntry implements
                         fileName = fileName.substring(2);
                     }
                 }
-            } else if (osname.indexOf("netware") > -1) {
+            } else if (osname.contains("netware")) {
                 int colon = fileName.indexOf(':');
                 if (colon != -1) {
                     fileName = fileName.substring(colon + 1);

Modified: commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/TarUtils.java
URL: http://svn.apache.org/viewvc/commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/TarUtils.java?rev=1650766&r1=1650765&r2=1650766&view=diff
==============================================================================
--- commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/TarUtils.java
(original)
+++ commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/tar/TarUtils.java
Sat Jan 10 16:15:54 2015
@@ -62,8 +62,7 @@ public class TarUtils {
                 final int length = buffer.length;
                 StringBuilder result = new StringBuilder(length);
 
-                for (int i = 0; i < length; ++i) {
-                    byte b = buffer[i];
+                for (byte b : buffer) {
                     if (b == 0) { // Trailing null
                         break;
                     }

Modified: commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ParallelScatterZipCreator.java
URL: http://svn.apache.org/viewvc/commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ParallelScatterZipCreator.java?rev=1650766&r1=1650765&r2=1650766&view=diff
==============================================================================
--- commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ParallelScatterZipCreator.java
(original)
+++ commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ParallelScatterZipCreator.java
Sat Jan 10 16:15:54 2015
@@ -40,7 +40,7 @@ import static java.util.Collections.sync
  * #ZipArchiveOutputStream *before* calling #writeTo on this class.</p>
  */
 public class ParallelScatterZipCreator {
-    private List<ScatterZipOutputStream> streams = synchronizedList(new ArrayList<ScatterZipOutputStream>());
+    private final List<ScatterZipOutputStream> streams = synchronizedList(new ArrayList<ScatterZipOutputStream>());
     private final ExecutorService es;
     private final ScatterGatherBackingStoreSupplier supplier;
 
@@ -49,7 +49,7 @@ public class ParallelScatterZipCreator {
     private long scatterDoneAt;
 
     private static class DefaultSupplier implements ScatterGatherBackingStoreSupplier {
-        AtomicInteger storeNum = new AtomicInteger(0);
+        final AtomicInteger storeNum = new AtomicInteger(0);
 
         public ScatterGatherBackingStore get() throws IOException {
             File tempFile = File.createTempFile("parallelscatter", "n" + storeNum.incrementAndGet());
@@ -64,7 +64,7 @@ public class ParallelScatterZipCreator {
         return new ScatterZipOutputStream(bs, sc);
     }
 
-    private ThreadLocal<ScatterZipOutputStream> tlScatterStreams = new ThreadLocal<ScatterZipOutputStream>()
{
+    private final ThreadLocal<ScatterZipOutputStream> tlScatterStreams = new ThreadLocal<ScatterZipOutputStream>()
{
         @Override
         protected ScatterZipOutputStream initialValue() {
             try {

Modified: commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ZipArchiveOutputStream.java
URL: http://svn.apache.org/viewvc/commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ZipArchiveOutputStream.java?rev=1650766&r1=1650765&r2=1650766&view=diff
==============================================================================
--- commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ZipArchiveOutputStream.java
(original)
+++ commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ZipArchiveOutputStream.java
Sat Jan 10 16:15:54 2015
@@ -1142,7 +1142,7 @@ public class ZipArchiveOutputStream exte
 
     private byte[] createCentralFileHeader(ZipArchiveEntry ze) throws IOException {
 
-        final long lfhOffset = offsets.get(ze).longValue();
+        final long lfhOffset = offsets.get(ze);
         final boolean needsZip64Extra = hasZip64Extra(ze)
                 || ze.getCompressedSize() >= ZIP64_MAGIC
                 || ze.getSize() >= ZIP64_MAGIC

Modified: commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ZipMethod.java
URL: http://svn.apache.org/viewvc/commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ZipMethod.java?rev=1650766&r1=1650765&r2=1650766&view=diff
==============================================================================
--- commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ZipMethod.java
(original)
+++ commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/zip/ZipMethod.java
Sat Jan 10 16:15:54 2015
@@ -175,7 +175,7 @@ public enum ZipMethod {
     static {
         Map<Integer, ZipMethod> cte = new HashMap<Integer, ZipMethod>();
         for (ZipMethod method : values()) {
-            cte.put(Integer.valueOf(method.getCode()), method);
+            cte.put(method.getCode(), method);
         }
         codeToEnum = Collections.unmodifiableMap(cte);
     }
@@ -208,6 +208,6 @@ public enum ZipMethod {
      * method is not known.
      */
     public static ZipMethod getMethodByCode(int code) {
-        return codeToEnum.get(Integer.valueOf(code));
+        return codeToEnum.get(code);
     }
 }

Modified: commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/compressors/z/ZCompressorInputStream.java
URL: http://svn.apache.org/viewvc/commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/compressors/z/ZCompressorInputStream.java?rev=1650766&r1=1650765&r2=1650766&view=diff
==============================================================================
--- commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/compressors/z/ZCompressorInputStream.java
(original)
+++ commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/compressors/z/ZCompressorInputStream.java
Sat Jan 10 16:15:54 2015
@@ -144,7 +144,7 @@ public class ZCompressorInputStream exte
                 addRepeatOfPreviousCode();
                 addedUnfinishedEntry = true;
             } else if (code > tableSize) {
-                throw new IOException(String.format("Invalid %d bit code 0x%x", Integer.valueOf(codeSize),
Integer.valueOf(code)));
+                throw new IOException(String.format("Invalid %d bit code 0x%x", codeSize,
code));
             }
             return expandCodeToOutputStack(code, addedUnfinishedEntry);
         }

Modified: commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/AbstractTestCase.java
URL: http://svn.apache.org/viewvc/commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/AbstractTestCase.java?rev=1650766&r1=1650765&r2=1650766&view=diff
==============================================================================
--- commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/AbstractTestCase.java
(original)
+++ commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/AbstractTestCase.java
Sat Jan 10 16:15:54 2015
@@ -121,8 +121,7 @@ public abstract class AbstractTestCase e
     }
 
     private static final boolean ON_WINDOWS =
-        System.getProperty("os.name").toLowerCase(Locale.ENGLISH)
-        .indexOf("windows") > -1;
+            System.getProperty("os.name").toLowerCase(Locale.ENGLISH).contains("windows");
 
     /**
      * Accommodate Windows bug encountered in both Sun and IBM JDKs.

Modified: commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/archivers/LongPathTest.java
URL: http://svn.apache.org/viewvc/commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/archivers/LongPathTest.java?rev=1650766&r1=1650765&r2=1650766&view=diff
==============================================================================
--- commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/archivers/LongPathTest.java
(original)
+++ commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/archivers/LongPathTest.java
Sat Jan 10 16:15:54 2015
@@ -140,12 +140,11 @@ public class LongPathTest extends Abstra
             assertTrue(ais instanceof ArArchiveInputStream);
             // CPIO does not store directories or directory names
             expected.clear();
-            for(int i=0; i < fileList.size(); i++){
-                String ent = fileList.get(i);
-                if (!ent.endsWith("/")){// not a directory
+            for (String ent : fileList) {
+                if (!ent.endsWith("/")) {// not a directory
                     final int lastSlash = ent.lastIndexOf('/');
                     if (lastSlash >= 0) { // extract path name
-                        expected.add(ent.substring(lastSlash+1, ent.length()));
+                        expected.add(ent.substring(lastSlash + 1, ent.length()));
                     } else {
                         expected.add(ent);
                     }

Modified: commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/UTF8ZipFilesTest.java
URL: http://svn.apache.org/viewvc/commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/UTF8ZipFilesTest.java?rev=1650766&r1=1650765&r2=1650766&view=diff
==============================================================================
--- commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/UTF8ZipFilesTest.java
(original)
+++ commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/archivers/zip/UTF8ZipFilesTest.java
Sat Jan 10 16:15:54 2015
@@ -366,8 +366,8 @@ public class UTF8ZipFilesTest extends Ab
     }
 
     public void testUtf8Interoperability() throws IOException {
-        File file1 = super.getFile("utf8-7zip-test.zip");
-        File file2 = super.getFile("utf8-winzip-test.zip");
+        File file1 = getFile("utf8-7zip-test.zip");
+        File file2 = getFile("utf8-winzip-test.zip");
 
         testFile(file1,CP437);
         testFile(file2,CP437);

Modified: commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/compressors/snappy/FramedSnappyCompressorInputStreamTest.java
URL: http://svn.apache.org/viewvc/commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/compressors/snappy/FramedSnappyCompressorInputStreamTest.java?rev=1650766&r1=1650765&r2=1650766&view=diff
==============================================================================
--- commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/compressors/snappy/FramedSnappyCompressorInputStreamTest.java
(original)
+++ commons/proper/compress/trunk/src/test/java/org/apache/commons/compress/compressors/snappy/FramedSnappyCompressorInputStreamTest.java
Sat Jan 10 16:15:54 2015
@@ -154,7 +154,7 @@ public final class FramedSnappyCompresso
             fail("expected an exception");
             in.close();
         } catch (IOException ex) {
-            assertTrue(ex.getMessage().indexOf("unskippable chunk") > -1);
+            assertTrue(ex.getMessage().contains("unskippable chunk"));
         }
     }
 



Mime
View raw message