From 28f3de6c698075c2282493309722c8c29e95b523 Mon Sep 17 00:00:00 2001 From: Neil Derraugh Date: Fri, 17 Apr 2020 13:35:30 -0400 Subject: ZipSlip test fails on Mac OS Mac OS has a symlink in the tmp dir that gets created in the test for ZipSlip. Using real paths prevents the test test from failing by using actual paths instead of a potentially different symlinked path to the canonical path. Issue-ID: SDC-2887 Signed-off-by: neil.derraugh Change-Id: Iafb0a84f6ab68276c5782c1ef716c59435aa72f5 --- .../src/test/java/org/openecomp/sdc/common/zip/ZipUtilsTest.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'common-app-api') diff --git a/common-app-api/src/test/java/org/openecomp/sdc/common/zip/ZipUtilsTest.java b/common-app-api/src/test/java/org/openecomp/sdc/common/zip/ZipUtilsTest.java index d5fb3dcc8b..bfd1046000 100644 --- a/common-app-api/src/test/java/org/openecomp/sdc/common/zip/ZipUtilsTest.java +++ b/common-app-api/src/test/java/org/openecomp/sdc/common/zip/ZipUtilsTest.java @@ -113,8 +113,8 @@ public class ZipUtilsTest { @Test public void testUnzipAndZip() throws IOException, ZipException { - final Path unzipTempPath = Files.createTempDirectory("testUnzip"); - final Path zipTempPath = Files.createTempDirectory("testZip"); + final Path unzipTempPath = Files.createTempDirectory("testUnzip").toRealPath(); + final Path zipTempPath = Files.createTempDirectory("testZip").toRealPath(); final Path testZipPath; try { try { -- cgit 1.2.3-korg