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-vfs.git
commit 393af9db3e192ff18f56634eed9cdf3558348ca7 Author: Gary Gregory <[email protected]> AuthorDate: Sat Dec 20 09:19:31 2025 -0500 Replace JUnit @DisplayName with Javadoc to make Maven output meaningful --- .../org/apache/commons/vfs2/FileTypeSelectorTest.java | 6 ++---- .../commons/vfs2/filter/NameFileFilterTest.java | 19 +++++++++---------- .../commons/vfs2/provider/http/HttpProviderTest.java | 6 ++---- .../vfs2/provider/local/LocalProviderTest.java | 3 +-- 4 files changed, 14 insertions(+), 20 deletions(-) diff --git a/commons-vfs2/src/test/java/org/apache/commons/vfs2/FileTypeSelectorTest.java b/commons-vfs2/src/test/java/org/apache/commons/vfs2/FileTypeSelectorTest.java index cdb1249b7..abfd1517d 100644 --- a/commons-vfs2/src/test/java/org/apache/commons/vfs2/FileTypeSelectorTest.java +++ b/commons-vfs2/src/test/java/org/apache/commons/vfs2/FileTypeSelectorTest.java @@ -20,15 +20,13 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import org.junit.jupiter.api.AfterAll; import org.junit.jupiter.api.BeforeAll; -import org.junit.jupiter.api.DisplayName; -import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.CsvSource; /** * Tests FileTypeSelector. */ -@DisplayName("FileTypeSelector Tests") +/** FileTypeSelector Tests */ public class FileTypeSelectorTest { private static FileObject baseFolder; @@ -69,7 +67,7 @@ public class FileTypeSelectorTest { "FILE, 5", "FOLDER, 8" }) - @DisplayName("Test file type selector with different file types") + /** Test file type selector with different file types */ public void testFileTypeSelector(final FileType fileType, final int expectedCount) throws Exception { final FileSelector selector = new FileTypeSelector(fileType); final FileObject[] foList = baseFolder.findFiles(selector); diff --git a/commons-vfs2/src/test/java/org/apache/commons/vfs2/filter/NameFileFilterTest.java b/commons-vfs2/src/test/java/org/apache/commons/vfs2/filter/NameFileFilterTest.java index 2734a2b8b..30a9087bc 100644 --- a/commons-vfs2/src/test/java/org/apache/commons/vfs2/filter/NameFileFilterTest.java +++ b/commons-vfs2/src/test/java/org/apache/commons/vfs2/filter/NameFileFilterTest.java @@ -23,7 +23,6 @@ import java.io.File; import java.util.ArrayList; import java.util.List; -import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.Nested; import org.junit.jupiter.api.Test; @@ -31,15 +30,15 @@ import org.junit.jupiter.api.Test; * Test for {@link NameFileFilter}. */ // CHECKSTYLE:OFF Test code -@DisplayName("NameFileFilter Tests") +/** NameFileFilter Tests */ public class NameFileFilterTest extends BaseFilterTest { @Nested - @DisplayName("List-based filtering") + /** List-based filtering */ class ListBasedFiltering { @Test - @DisplayName("Should accept files matching names in list (default case sensitivity)") + /** Should accept files matching names in list (default case sensitivity) */ public void testAcceptList() { // PREPARE final List<String> list = new ArrayList<>(); @@ -55,7 +54,7 @@ public class NameFileFilterTest extends BaseFilterTest { } @Test - @DisplayName("Should accept files matching names in list (case insensitive)") + /** Should accept files matching names in list (case insensitive) */ public void testAcceptListIOCaseInsensitive() { // PREPARE final List<String> list = new ArrayList<>(); @@ -71,7 +70,7 @@ public class NameFileFilterTest extends BaseFilterTest { } @Test - @DisplayName("Should accept files matching names in list (case sensitive)") + /** Should accept files matching names in list (case sensitive) */ public void testAcceptListIOCaseSensitive() { // PREPARE final List<String> list = new ArrayList<>(); @@ -88,11 +87,11 @@ public class NameFileFilterTest extends BaseFilterTest { } @Nested - @DisplayName("String-based filtering") + /** String-based filtering */ class StringBasedFiltering { @Test - @DisplayName("Should accept files matching exact name (default case sensitivity)") + /** Should accept files matching exact name (default case sensitivity) */ public void testAcceptString() { // PREPARE final NameFileFilter filter = new NameFileFilter("test1.txt"); @@ -105,7 +104,7 @@ public class NameFileFilterTest extends BaseFilterTest { } @Test - @DisplayName("Should accept files matching exact name (case insensitive)") + /** Should accept files matching exact name (case insensitive) */ public void testAcceptStringIOCaseInsensitive() { // PREPARE final NameFileFilter filter = new NameFileFilter(IOCase.INSENSITIVE, "test2.txt"); @@ -118,7 +117,7 @@ public class NameFileFilterTest extends BaseFilterTest { } @Test - @DisplayName("Should accept files matching exact name (case sensitive)") + /** Should accept files matching exact name (case sensitive) */ public void testAcceptStringIOCaseSensitive() { // PREPARE final NameFileFilter filter = new NameFileFilter(IOCase.SENSITIVE, "test2.txt"); diff --git a/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http/HttpProviderTest.java b/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http/HttpProviderTest.java index 81b2318c9..930a552e7 100644 --- a/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http/HttpProviderTest.java +++ b/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http/HttpProviderTest.java @@ -17,6 +17,7 @@ package org.apache.commons.vfs2.provider.http; import static org.apache.commons.vfs2.VfsTestUtils.getTestDirectory; +import static org.junit.jupiter.api.Assertions.assertEquals; import java.io.File; import java.time.Duration; @@ -32,20 +33,17 @@ import org.apache.commons.vfs2.VFS; import org.apache.commons.vfs2.impl.DefaultFileSystemManager; import org.apache.commons.vfs2.util.NHttpFileServer; import org.junit.jupiter.api.Assertions; -import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.TestInstance; -import static org.junit.jupiter.api.Assertions.assertEquals; - /** * JUnit 5 test cases for the HTTP provider. * <p> * This class replaces {@link HttpProviderTestCase} with a pure JUnit 5 implementation. * </p> */ -@DisplayName("HTTP Provider Tests") +/** HTTP Provider Tests */ @Tag("provider") @Tag("http") @Tag("network") diff --git a/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/local/LocalProviderTest.java b/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/local/LocalProviderTest.java index 0f8d015a5..a41f552c1 100644 --- a/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/local/LocalProviderTest.java +++ b/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/local/LocalProviderTest.java @@ -24,7 +24,6 @@ import org.apache.commons.vfs2.FileObject; import org.apache.commons.vfs2.FileSystemManager; import org.apache.commons.vfs2.PermissionsTests; import org.apache.commons.vfs2.ProviderTestSuiteJunit5; -import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.TestInstance; @@ -34,7 +33,7 @@ import org.junit.jupiter.api.TestInstance; * This class replaces {@link LocalProviderTestCase} with a pure JUnit 5 implementation. * </p> */ -@DisplayName("Local File System Provider Tests") +/** Local File System Provider Tests */ @Tag("provider") @Tag("local") @Tag("filesystem")
