Remove '/resources/**' mapping and default servlet
Remove '/resources/**' mapping since it can cause problems with the '/**' when the developer defines their own 'resources' sub-folder. Also remove default servlet config since the resources mapping renders it redundant. Issue: #55494446
This commit is contained in:
@@ -3,8 +3,8 @@
|
||||
<head>
|
||||
<title>Layout</title>
|
||||
<link rel="stylesheet"
|
||||
th:href="@{/resources/css/bootstrap.min.css}"
|
||||
href="../../resources/css/bootstrap.min.css"/>
|
||||
th:href="@{/css/bootstrap.min.css}"
|
||||
href="../../css/bootstrap.min.css"/>
|
||||
</head>
|
||||
<body>
|
||||
<div class="container">
|
||||
@@ -29,4 +29,4 @@
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
|
||||
@@ -26,7 +26,7 @@ import static org.junit.Assert.assertTrue;
|
||||
|
||||
/**
|
||||
* Basic integration tests for demo application.
|
||||
*
|
||||
*
|
||||
* @author Dave Syer
|
||||
*/
|
||||
public class SampleWebUiApplicationTests {
|
||||
@@ -78,7 +78,7 @@ public class SampleWebUiApplicationTests {
|
||||
@Test
|
||||
public void testCss() throws Exception {
|
||||
ResponseEntity<String> entity = getRestTemplate().getForEntity(
|
||||
"http://localhost:8080/resources/css/bootstrap.min.css", String.class);
|
||||
"http://localhost:8080/css/bootstrap.min.css", String.class);
|
||||
assertEquals(HttpStatus.OK, entity.getStatusCode());
|
||||
assertTrue("Wrong body:\n" + entity.getBody(), entity.getBody().contains("body"));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user