Skip to content

Commit

Permalink
fix: disable simultaneous tests on Windows
Browse files Browse the repository at this point in the history
Cannot figure out where the bottleneck is.
  • Loading branch information
manusa committed Dec 22, 2022
1 parent 0b1e796 commit 4d04bf9
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.DisplayName;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.condition.DisabledOnOs;
import org.junit.jupiter.api.condition.OS;

import java.io.Closeable;
import java.io.IOException;
Expand Down Expand Up @@ -92,6 +94,7 @@ private void withHttp1() throws IOException {

@Test
@DisplayName("Should be able to make 1024 simultaneous HTTP/1.x connections before processing the response")
@DisabledOnOs(OS.WINDOWS)
public void http1Connections() throws Exception {
final CountDownLatch activeConnections = new CountDownLatch(MAX_HTTP_1_CONNECTIONS);
httpServer.createContext("/http", exchange -> {
Expand Down Expand Up @@ -119,6 +122,7 @@ public void http1Connections() throws Exception {

@Test
@DisplayName("Should be able to make 1024 simultaneous HTTP connections before upgrading to WebSocket")
@DisabledOnOs(OS.WINDOWS)
public void http1WebSocketConnectionsBeforeUpgrade() throws Exception {
final CountDownLatch activeConnections = new CountDownLatch(MAX_HTTP_1_CONNECTIONS);
httpServer.createContext("/http", exchange -> {
Expand All @@ -143,6 +147,7 @@ public void http1WebSocketConnectionsBeforeUpgrade() throws Exception {

@Test
@DisplayName("Should be able to make 1024 simultaneous upgraded WebSocket connections")
@DisabledOnOs(OS.WINDOWS)
public void http1WebSocketConnections() throws Exception {
withHttp1();
final Collection<okhttp3.WebSocket> serverSockets = ConcurrentHashMap.newKeySet();
Expand Down

0 comments on commit 4d04bf9

Please sign in to comment.