diff --git a/kubernetes-client-api/src/test/java/io/fabric8/kubernetes/client/http/AbstractHttpClientNewWebSocketBuilderTest.java b/kubernetes-client-api/src/test/java/io/fabric8/kubernetes/client/http/AbstractHttpClientNewWebSocketBuilderTest.java index fd24e7e66c..087c77a9f1 100644 --- a/kubernetes-client-api/src/test/java/io/fabric8/kubernetes/client/http/AbstractHttpClientNewWebSocketBuilderTest.java +++ b/kubernetes-client-api/src/test/java/io/fabric8/kubernetes/client/http/AbstractHttpClientNewWebSocketBuilderTest.java @@ -98,7 +98,7 @@ void buildAsyncReceivesMultipleMessages() throws Exception { .always(); final CountDownLatch latch = new CountDownLatch(2); final Set messages = ConcurrentHashMap.newKeySet(); - final WebSocket ws = httpClient.newWebSocketBuilder() + httpClient.newWebSocketBuilder() .uri(URI.create(server.url("/websocket-multiple-message"))) .buildAsync(new WebSocket.Listener() { @Override @@ -157,6 +157,7 @@ void buildAsyncIncludesRequiredHeaders() throws Exception { server.expect().withPath("/websocket-headers-test") .andUpgradeToWebSocket() .open() + .waitFor(50L).andEmit("OK") .done() .always(); httpClient.newWebSocketBuilder()