Skip to content

Commit

Permalink
Update to commons-io 2.17 and junit 4.13.2
Browse files Browse the repository at this point in the history
Adjust test expectations accordingly. It's best to update to latest
versions while at it so hopefully next CVE is not soon.
  • Loading branch information
akurtakov committed Oct 4, 2024
1 parent fa370fa commit c153faa
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.13.1</version>
<version>4.13.2</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>2.14.0</version>
<version>2.17.0</version>
</dependency>
<dependency>
<groupId>commons-beanutils</groupId>
Expand Down
Original file line number Diff line number Diff line change
@@ -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
Expand Down Expand Up @@ -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());
Expand All @@ -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]);
}

Expand Down Expand Up @@ -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]);
}

Expand Down

0 comments on commit c153faa

Please sign in to comment.