Merge branch '2.0.x'

pull/13757/head
Andy Wilkinson 6 years ago
commit 1ea91ece23

@ -465,10 +465,6 @@ public abstract class EndpointDiscoverer<E extends ExposableEndpoint<O>, O exten
return this.id;
}
public Class<?> getType() {
return this.bean.getClass();
}
public boolean isEnabledByDefault() {
return this.enabledByDefault;
}

@ -35,7 +35,7 @@ import static org.mockito.Mockito.mock;
*
* @author Yulin Qin
*/
public class MongoReactiveHealthIndicatorTest {
public class MongoReactiveHealthIndicatorTests {
@Test
public void testMongoIsUp() {
@ -65,7 +65,8 @@ public class MongoReactiveHealthIndicatorTest {
StepVerifier.create(health).consumeNextWith((h) -> {
assertThat(h.getStatus()).isEqualTo(Status.DOWN);
assertThat(h.getDetails()).containsOnlyKeys("error");
assertThat(h.getDetails().get("error")).isEqualTo("Connection failed");
assertThat(h.getDetails().get("error"))
.isEqualTo(MongoException.class.getName() + ": Connection failed");
}).verifyComplete();
}

@ -73,7 +73,6 @@ import static org.springframework.web.reactive.function.server.RouterFunctions.r
public class MappingsEndpointTests {
@Test
@SuppressWarnings("unchecked")
public void servletWebMappings() {
Supplier<ConfigurableWebApplicationContext> contextSupplier = prepareContextSupplier();
new WebApplicationContextRunner(contextSupplier)
@ -100,7 +99,6 @@ public class MappingsEndpointTests {
}
@Test
@SuppressWarnings("unchecked")
public void servletWebMappingsWithAdditionalDispatcherServlets() {
Supplier<ConfigurableWebApplicationContext> contextSupplier = prepareContextSupplier();
new WebApplicationContextRunner(contextSupplier).withUserConfiguration(
@ -121,6 +119,7 @@ public class MappingsEndpointTests {
});
}
@SuppressWarnings("unchecked")
private Supplier<ConfigurableWebApplicationContext> prepareContextSupplier() {
ServletContext servletContext = mock(ServletContext.class);
given(servletContext.getInitParameterNames())

Loading…
Cancel
Save