Projects
openEuler:24.03:SP1:Everything
openjdk-1.8.0
_service:tar_scm:add-8226530-test-case-fixed.patch
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File _service:tar_scm:add-8226530-test-case-fixed.patch of Package openjdk-1.8.0
From 6430afa36959aa740f47d64427f06c755ea1549f Mon Sep 17 00:00:00 2001 Date: Thu, 21 Sep 2023 15:25:27 +0800 Subject: add 8226530-test-case-fixed --- jdk/test/java/util/zip/ZipFile/Zip64SizeTest.java | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/jdk/test/java/util/zip/ZipFile/Zip64SizeTest.java b/jdk/test/java/util/zip/ZipFile/Zip64SizeTest.java index be701e480..c466ffa07 100644 --- a/jdk/test/java/util/zip/ZipFile/Zip64SizeTest.java +++ b/jdk/test/java/util/zip/ZipFile/Zip64SizeTest.java @@ -26,7 +26,8 @@ import org.testng.annotations.Test; import java.io.*; import java.nio.file.Files; -import java.nio.file.Path; +import java.nio.file.Paths; +import java.util.Arrays; import java.util.List; import java.util.zip.ZipEntry; import java.util.zip.ZipFile; @@ -52,7 +53,7 @@ public class Zip64SizeTest { // File that will be created with a size less than 0xFFFFFFFF private static final String SMALL_FILE_NAME = "SmallZipEntry.txt"; // List of files to be added to the ZIP file - private static final List<String> ZIP_ENTRIES = List.of(LARGE_FILE_NAME, + private static final List<String> ZIP_ENTRIES = Arrays.asList(LARGE_FILE_NAME, SMALL_FILE_NAME); private static final long LARGE_FILE_SIZE = 5L * 1024L * 1024L * 1024L; // 5GB private static final long SMALL_FILE_SIZE = 0x100000L; // 1024L x 1024L; @@ -83,9 +84,9 @@ public class Zip64SizeTest { * @throws IOException if an error occurs deleting the files */ private static void deleteFiles() throws IOException { - Files.deleteIfExists(Path.of(ZIP_FILE_NAME)); - Files.deleteIfExists(Path.of(LARGE_FILE_NAME)); - Files.deleteIfExists(Path.of(SMALL_FILE_NAME)); + Files.deleteIfExists(Paths.get(ZIP_FILE_NAME)); + Files.deleteIfExists(Paths.get(LARGE_FILE_NAME)); + Files.deleteIfExists(Paths.get(SMALL_FILE_NAME)); } /** @@ -144,4 +145,4 @@ public class Zip64SizeTest { public void tearDown() throws IOException { deleteFiles(); } -} \ No newline at end of file +} -- 2.22.0
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.
浙ICP备2022010568号-2