Skip to content

Commit 6dd23f9

Browse files
committed
Increase more SignalR Java client test timeouts
1 parent bc56ee1 commit 6dd23f9

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

src/SignalR/clients/java/signalr/test/src/main/java/com/microsoft/signalr/HubConnectionTest.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2583,14 +2583,14 @@ public void throwFromOnHandlerRunsAllHandlers() {
25832583
value2.set(param1);
25842584
}, String.class);
25852585

2586-
hubConnection.start().timeout(1, TimeUnit.SECONDS).blockingAwait();
2586+
hubConnection.start().timeout(30, TimeUnit.SECONDS).blockingAwait();
25872587
mockTransport.receiveMessage("{\"type\":1,\"target\":\"inc\",\"arguments\":[\"Hello World\"]}" + RECORD_SEPARATOR);
25882588

25892589
// Confirming that our handler was called and the correct message was passed in.
25902590
assertEquals("Hello World", value1.get());
25912591
assertEquals("Hello World", value2.get());
25922592

2593-
hubConnection.stop().timeout(1, TimeUnit.SECONDS).blockingAwait();
2593+
hubConnection.stop().timeout(30, TimeUnit.SECONDS).blockingAwait();
25942594

25952595
ILoggingEvent log = logger.assertLog("Invoking client side method 'inc' failed:");
25962596
assertEquals("throw from on handler", log.getThrowableProxy().getMessage());
@@ -3189,10 +3189,10 @@ public void stopWithoutObservingWithLongPollingTransportStops() {
31893189
closed.onComplete();
31903190
});
31913191

3192-
hubConnection.start().timeout(1, TimeUnit.SECONDS).blockingAwait();
3192+
hubConnection.start().timeout(30, TimeUnit.SECONDS).blockingAwait();
31933193

31943194
hubConnection.stop();
3195-
closed.timeout(1, TimeUnit.SECONDS).blockingAwait();
3195+
closed.timeout(30, TimeUnit.SECONDS).blockingAwait();
31963196
blockGet.onComplete();
31973197
assertEquals(HubConnectionState.DISCONNECTED, hubConnection.getConnectionState());
31983198
}
@@ -3227,12 +3227,12 @@ public void hubConnectionClosesAndRunsOnClosedCallbackAfterCloseMessageWithLongP
32273227
hubConnection.onClosed((ex) -> {
32283228
closed.onComplete();
32293229
});
3230-
hubConnection.start().timeout(1, TimeUnit.SECONDS).blockingAwait();
3230+
hubConnection.start().timeout(30, TimeUnit.SECONDS).blockingAwait();
32313231

32323232
assertEquals(HubConnectionState.CONNECTED, hubConnection.getConnectionState());
32333233
blockGet.onComplete();
32343234

3235-
closed.timeout(1, TimeUnit.SECONDS).blockingAwait();
3235+
closed.timeout(30, TimeUnit.SECONDS).blockingAwait();
32363236

32373237
assertEquals(HubConnectionState.DISCONNECTED, hubConnection.getConnectionState());
32383238
}

src/SignalR/clients/java/signalr/test/src/main/java/com/microsoft/signalr/LongPollingTransportTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -392,7 +392,7 @@ public void ErrorFromClosePropagatesOnSecondStopCall() {
392392
Map<String, String> headers = new HashMap<>();
393393
LongPollingTransport transport = new LongPollingTransport(headers, client, Single.just(""));
394394

395-
transport.start("http://example.com").timeout(100, TimeUnit.SECONDS).blockingAwait();
395+
transport.start("http://example.com").timeout(30, TimeUnit.SECONDS).blockingAwait();
396396

397397
RuntimeException exception = assertThrows(RuntimeException.class, () -> transport.stop().blockingAwait(100, TimeUnit.SECONDS));
398398
assertEquals("Request has no handler: DELETE http://example.com", exception.getMessage());

0 commit comments

Comments
 (0)