This is an automated email from the ASF dual-hosted git repository.

ggregory pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-compress.git


The following commit(s) were added to refs/heads/master by this push:
     new 23b0a370 Remove unnecessary casts
23b0a370 is described below

commit 23b0a3707db54ea40cfd5be463d1cad26bd7789e
Author: Gary Gregory <garydgreg...@gmail.com>
AuthorDate: Thu Nov 2 18:48:08 2023 -0400

    Remove unnecessary casts
---
 src/test/java/org/apache/commons/compress/archivers/ZipTestCase.java    | 2 +-
 .../org/apache/commons/compress/archivers/zip/UTF8ZipFilesTest.java     | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git 
a/src/test/java/org/apache/commons/compress/archivers/ZipTestCase.java 
b/src/test/java/org/apache/commons/compress/archivers/ZipTestCase.java
index 010031b8..8aae84b9 100644
--- a/src/test/java/org/apache/commons/compress/archivers/ZipTestCase.java
+++ b/src/test/java/org/apache/commons/compress/archivers/ZipTestCase.java
@@ -866,7 +866,7 @@ public final class ZipTestCase extends AbstractTestCase {
         final File input = getFile("bla.zip");
         try (final InputStream is = Files.newInputStream(input.toPath());
                 final ArchiveInputStream<ZipArchiveEntry> in = 
ArchiveStreamFactory.DEFAULT.createArchiveInputStream("zip", is)) {
-            final ZipArchiveEntry entry = (ZipArchiveEntry) in.getNextEntry();
+            final ZipArchiveEntry entry = in.getNextEntry();
             Files.copy(in, new File(dir, entry.getName()).toPath());
         }
     }
diff --git 
a/src/test/java/org/apache/commons/compress/archivers/zip/UTF8ZipFilesTest.java 
b/src/test/java/org/apache/commons/compress/archivers/zip/UTF8ZipFilesTest.java
index 5d139376..f91d9d23 100644
--- 
a/src/test/java/org/apache/commons/compress/archivers/zip/UTF8ZipFilesTest.java
+++ 
b/src/test/java/org/apache/commons/compress/archivers/zip/UTF8ZipFilesTest.java
@@ -239,7 +239,7 @@ public class UTF8ZipFilesTest extends AbstractTestCase {
     @Test
     public void testRawNameReadFromStream() throws IOException {
         try (ZipArchiveInputStream zi = new 
ZipArchiveInputStream(newInputStream("utf8-7zip-test.zip"), CP437, false)) {
-            assertRawNameOfAcsiiTxt((ZipArchiveEntry) zi.getNextEntry());
+            assertRawNameOfAcsiiTxt(zi.getNextEntry());
         }
     }
 

Reply via email to