diff --git a/jetty-webapp/pom.xml b/jetty-webapp/pom.xml
index 76a0f1b47885..3e9055d2d181 100644
--- a/jetty-webapp/pom.xml
+++ b/jetty-webapp/pom.xml
@@ -96,6 +96,12 @@
jetty-slf4j-impl
test
+
+ org.eclipse.jetty.tests
+ jetty-http-tools
+ ${project.version}
+ test
+
org.eclipse.jetty.toolchain
jetty-test-helper
diff --git a/jetty-webapp/src/test/java/org/eclipse/jetty/webapp/WebAppClassLoaderTest.java b/jetty-webapp/src/test/java/org/eclipse/jetty/webapp/WebAppClassLoaderTest.java
index 51db274b7e1d..af5574c3146f 100644
--- a/jetty-webapp/src/test/java/org/eclipse/jetty/webapp/WebAppClassLoaderTest.java
+++ b/jetty-webapp/src/test/java/org/eclipse/jetty/webapp/WebAppClassLoaderTest.java
@@ -20,7 +20,6 @@
import java.io.InputStream;
import java.lang.instrument.ClassFileTransformer;
-import java.lang.instrument.IllegalClassFormatException;
import java.net.URI;
import java.net.URL;
import java.nio.file.Path;
@@ -45,6 +44,7 @@
import static org.hamcrest.Matchers.notNullValue;
import static org.hamcrest.Matchers.nullValue;
import static org.junit.jupiter.api.Assertions.assertFalse;
+import static org.junit.jupiter.api.Assertions.assertNotNull;
import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.junit.jupiter.api.Assertions.assertTrue;
import static org.junit.jupiter.api.Assumptions.assumeTrue;
@@ -79,7 +79,7 @@ public void assertCanLoadClass(String clazz) throws ClassNotFoundException
assertThat("Can Load Class [" + clazz + "]", _loader.loadClass(clazz), notNullValue());
}
- public void assertCanLoadResource(String res) throws ClassNotFoundException
+ public void assertCanLoadResource(String res)
{
assertThat("Can Load Resource [" + res + "]", _loader.getResource(res), notNullValue());
}
@@ -112,7 +112,7 @@ public void testParentLoad() throws Exception
assertCantLoadClass("org.eclipse.jetty.webapp.Configuration");
Class> clazzA = _loader.loadClass("org.acme.webapp.ClassInJarA");
- assertTrue(clazzA.getField("FROM_PARENT") != null);
+ assertNotNull(clazzA.getField("FROM_PARENT"));
}
@Test
@@ -131,21 +131,18 @@ public void testWebAppLoad() throws Exception
Class> clazzA = _loader.loadClass("org.acme.webapp.ClassInJarA");
assertThrows(NoSuchFieldException.class, () ->
- {
- clazzA.getField("FROM_PARENT");
- });
+ clazzA.getField("FROM_PARENT"));
}
@Test
public void testClassFileTranslations() throws Exception
{
- final List