diff --git a/jetty-webapp/src/test/java/org/eclipse/jetty/webapp/WebInfConfigurationTest.java b/jetty-webapp/src/test/java/org/eclipse/jetty/webapp/WebInfConfigurationTest.java index d5a3c20a738e..962c0eb8e054 100644 --- a/jetty-webapp/src/test/java/org/eclipse/jetty/webapp/WebInfConfigurationTest.java +++ b/jetty-webapp/src/test/java/org/eclipse/jetty/webapp/WebInfConfigurationTest.java @@ -21,6 +21,7 @@ import java.io.IOException; import java.nio.file.Path; import java.util.List; +import java.util.stream.Collectors; import java.util.stream.Stream; import org.eclipse.jetty.toolchain.test.FS; @@ -72,7 +73,7 @@ public void testFindAndFilterContainerPaths() context.setClassLoader(loader); config.findAndFilterContainerPaths(context); List containerResources = context.getMetaData().getContainerResources(); - assertEquals(1, containerResources.size()); + assertEquals(1, containerResources.size(), () -> containerResources.stream().map(Resource::toString).collect(Collectors.joining(",", "[", "]"))); assertThat(containerResources.get(0).toString(), containsString("jetty-util")); } @@ -93,7 +94,7 @@ public void testFindAndFilterContainerPathsJDK9() context.setClassLoader(loader); config.findAndFilterContainerPaths(context); List containerResources = context.getMetaData().getContainerResources(); - assertEquals(2, containerResources.size()); + assertEquals(2, containerResources.size(), () -> containerResources.stream().map(Resource::toString).collect(Collectors.joining(",", "[", "]"))); for (Resource r : containerResources) { String s = r.toString(); @@ -121,7 +122,7 @@ public void testFindAndFilterContainerPathsTarget8() context.setClassLoader(loader); config.findAndFilterContainerPaths(context); List containerResources = context.getMetaData().getContainerResources(); - assertEquals(1, containerResources.size()); + assertEquals(1, containerResources.size(), () -> containerResources.stream().map(Resource::toString).collect(Collectors.joining(",", "[", "]"))); assertThat(containerResources.get(0).toString(), containsString("jetty-util")); }