From 918d803f76fd592145fe45d5fbbaae9d848b4ed7 Mon Sep 17 00:00:00 2001 From: Brian Clozel Date: Mon, 21 Aug 2017 16:20:15 +0200 Subject: [PATCH] Remove start/stop integration test This test is not useful in this context. Closes gh-9889 --- ...AbstractReactiveWebServerFactoryTests.java | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/spring-boot/src/test/java/org/springframework/boot/web/reactive/server/AbstractReactiveWebServerFactoryTests.java b/spring-boot/src/test/java/org/springframework/boot/web/reactive/server/AbstractReactiveWebServerFactoryTests.java index 07fd2f1c0f..2c51c47c6f 100644 --- a/spring-boot/src/test/java/org/springframework/boot/web/reactive/server/AbstractReactiveWebServerFactoryTests.java +++ b/spring-boot/src/test/java/org/springframework/boot/web/reactive/server/AbstractReactiveWebServerFactoryTests.java @@ -22,7 +22,6 @@ import org.junit.Test; import org.junit.rules.ExpectedException; import org.junit.rules.TemporaryFolder; import reactor.core.publisher.Mono; -import reactor.test.StepVerifier; import org.springframework.boot.testsupport.rule.OutputCapture; import org.springframework.boot.web.server.WebServer; @@ -33,7 +32,6 @@ import org.springframework.http.server.reactive.ServerHttpRequest; import org.springframework.http.server.reactive.ServerHttpResponse; import org.springframework.util.SocketUtils; import org.springframework.web.reactive.function.BodyInserters; -import org.springframework.web.reactive.function.client.ClientResponse; import org.springframework.web.reactive.function.client.WebClient; import static org.assertj.core.api.Assertions.assertThat; @@ -70,23 +68,6 @@ public abstract class AbstractReactiveWebServerFactoryTests { protected abstract AbstractReactiveWebServerFactory getFactory(); - @Test - public void startStopServer() { - this.webServer = getFactory().getWebServer(new EchoHandler()); - this.webServer.start(); - assertThat(this.output.toString()).contains("started on port"); - Mono result = getWebClient().post().uri("/test") - .contentType(MediaType.TEXT_PLAIN) - .body(BodyInserters.fromObject("Hello World")).exchange() - .flatMap((response) -> response.bodyToMono(String.class)); - assertThat(result.block()).isEqualTo("Hello World"); - this.webServer.stop(); - Mono response = getWebClient().post().uri("/test") - .contentType(MediaType.TEXT_PLAIN) - .body(BodyInserters.fromObject("Hello World")).exchange(); - StepVerifier.create(response).expectError().verify(); - } - @Test public void specificPort() throws Exception { AbstractReactiveWebServerFactory factory = getFactory();