From c153faa8aa9286f51fa35b7123718a96fc3a7bd5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=90=D0=BB=D0=B5=D0=BA=D1=81=D0=B0=D0=BD=D0=B4=D1=8A?= =?UTF-8?q?=D1=80=20=D0=9A=D1=83=D1=80=D1=82=D0=B0=D0=BA=D0=BE=D0=B2?= Date: Fri, 4 Oct 2024 08:03:48 +0300 Subject: [PATCH] Update to commons-io 2.17 and junit 4.13.2 Adjust test expectations accordingly. It's best to update to latest versions while at it so hopefully next CVE is not soon. --- .../526858-test-classpath/jar-dependencies/pom.xml | 4 ++-- .../org/eclipse/m2e/tests/jdt/JavaClasspathTest.java | 10 +++++----- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/org.eclipse.m2e.tests/projects/526858-test-classpath/jar-dependencies/pom.xml b/org.eclipse.m2e.tests/projects/526858-test-classpath/jar-dependencies/pom.xml index 97377a9e7..20c1f82c0 100644 --- a/org.eclipse.m2e.tests/projects/526858-test-classpath/jar-dependencies/pom.xml +++ b/org.eclipse.m2e.tests/projects/526858-test-classpath/jar-dependencies/pom.xml @@ -14,13 +14,13 @@ junit junit - 4.13.1 + 4.13.2 test commons-io commons-io - 2.14.0 + 2.17.0 commons-beanutils diff --git a/org.eclipse.m2e.tests/src/org/eclipse/m2e/tests/jdt/JavaClasspathTest.java b/org.eclipse.m2e.tests/src/org/eclipse/m2e/tests/jdt/JavaClasspathTest.java index 7478cfe99..fa9e32eb9 100644 --- a/org.eclipse.m2e.tests/src/org/eclipse/m2e/tests/jdt/JavaClasspathTest.java +++ b/org.eclipse.m2e.tests/src/org/eclipse/m2e/tests/jdt/JavaClasspathTest.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2010, 2021 Sonatype, Inc. + * Copyright (c) 2010, 2024 Sonatype, Inc. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License 2.0 * which accompanies this distribution, and is available at @@ -355,10 +355,10 @@ public void test526858_TestClasspathAttributeOnJar() throws Exception { .getClasspathEntries(); assertEquals("" + Arrays.asList(classpathEntries), 6, classpathEntries.length); //test dependency - assertEquals("junit-4.13.1.jar", classpathEntries[0].getPath().lastSegment()); + assertEquals("junit-4.13.2.jar", classpathEntries[0].getPath().lastSegment()); assertTest(classpathEntries[0]); //compile dependency - assertEquals("commons-io-2.7.jar", classpathEntries[2].getPath().lastSegment()); + assertEquals("commons-io-2.17.0.jar", classpathEntries[2].getPath().lastSegment()); assertNotTest(classpathEntries[2]); //test + transitive test dependencies assertEquals("commons-beanutils-1.9.4.jar", classpathEntries[3].getPath().lastSegment()); @@ -381,7 +381,7 @@ public void test526858_TestClasspathAttributeOnProject() throws Exception { assertDoesntExportTests(classpathEntries[0]); //transitive test dependency - assertEquals("commons-io-2.7.jar", classpathEntries[1].getPath().lastSegment()); + assertEquals("commons-io-2.17.0.jar", classpathEntries[1].getPath().lastSegment()); assertTest(classpathEntries[1]); } @@ -436,7 +436,7 @@ public void test526858_ProjectExportingTests() throws Exception { assertExportsTests(classpathEntries[0]); //transitive dependency - assertEquals("commons-io-2.7.jar", classpathEntries[1].getPath().lastSegment()); + assertEquals("commons-io-2.17.0.jar", classpathEntries[1].getPath().lastSegment()); assertNotTest(classpathEntries[1]); }