This commit is contained in:
Andy Wilkinson
2017-08-04 11:00:36 +01:00
parent 6090fd3eb0
commit e9aeb9ad63
2 changed files with 15 additions and 20 deletions

View File

@@ -52,10 +52,9 @@ public class TomcatEmbeddedWebappClassLoaderTests {
@Test
public void getResourceFindsResourceFromParentClassLoader() throws Exception {
File war = createWar();
withWebappClassLoader(war, (classLoader) -> {
assertThat(classLoader.getResource("test.txt"))
.isEqualTo(new URL(webInfClassesUrlString(war) + "test.txt"));
});
withWebappClassLoader(war,
(classLoader) -> assertThat(classLoader.getResource("test.txt"))
.isEqualTo(new URL(webInfClassesUrlString(war) + "test.txt")));
}
@Test