Skip to content

Commit b5653ad

Browse files
committed
Merge branch '2.4.x' into 2.5.x
2 parents 42704f0 + f3b5e6b commit b5653ad

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

spring-boot-project/spring-boot-autoconfigure/src/test/java/org/springframework/boot/autoconfigure/web/reactive/WebFluxAutoConfigurationTests.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@
5151
import org.springframework.core.Ordered;
5252
import org.springframework.core.annotation.Order;
5353
import org.springframework.core.convert.ConversionService;
54+
import org.springframework.core.io.ClassPathResource;
5455
import org.springframework.format.Parser;
5556
import org.springframework.format.Printer;
5657
import org.springframework.format.support.FormattingConversionService;
@@ -157,13 +158,12 @@ void shouldRegisterResourceHandlerMapping() {
157158
SimpleUrlHandlerMapping hm = context.getBean("resourceHandlerMapping", SimpleUrlHandlerMapping.class);
158159
assertThat(hm.getUrlMap().get("/**")).isInstanceOf(ResourceWebHandler.class);
159160
ResourceWebHandler staticHandler = (ResourceWebHandler) hm.getUrlMap().get("/**");
160-
assertThat(staticHandler).extracting("locationValues").asList().hasSize(4);
161-
assertThat(staticHandler.getLocations()).hasSize(1);
162-
assertThat(staticHandler.getLocations().get(0)).hasToString("class path resource [public/]");
161+
assertThat(staticHandler.getLocations()).hasSize(4);
163162
assertThat(hm.getUrlMap().get("/webjars/**")).isInstanceOf(ResourceWebHandler.class);
164163
ResourceWebHandler webjarsHandler = (ResourceWebHandler) hm.getUrlMap().get("/webjars/**");
165-
assertThat(webjarsHandler).extracting("locationValues").asList()
166-
.containsExactly("classpath:/META-INF/resources/webjars/");
164+
assertThat(webjarsHandler.getLocations()).hasSize(1);
165+
assertThat(webjarsHandler.getLocations().get(0))
166+
.isEqualTo(new ClassPathResource("/META-INF/resources/webjars/"));
167167
});
168168
}
169169

0 commit comments

Comments
 (0)