testing: Wait for TIMEOUT_MS instead of 100ms

The transport test flakes at the timeout(100) about .05% of the time.
There's really no reason it should have a smaller timeout compared to
the other timeouts.

The timeout(250) wasn't flaking at all, but it should follow the
convention.
This commit is contained in:
Eric Anderson 2018-09-29 07:01:43 -07:00
parent 4c5dabf705
commit f2e34d772b
1 changed files with 2 additions and 2 deletions

View File

@ -279,7 +279,7 @@ public abstract class AbstractTransportTest {
serverStreamCreation.stream.writeHeaders(new Metadata());
serverStreamCreation.stream.flush();
verify(mockClientStreamListener2, timeout(250)).headersRead(any(Metadata.class));
verify(mockClientStreamListener2, timeout(TIMEOUT_MS)).headersRead(any(Metadata.class));
}
@Test
@ -1812,7 +1812,7 @@ public abstract class AbstractTransportTest {
ManagedClientTransport clientTransport,
ManagedClientTransport.Listener listener) {
runIfNotNull(clientTransport.start(listener));
verify(listener, timeout(100)).transportReady();
verify(listener, timeout(TIMEOUT_MS)).transportReady();
}
private static class MockServerListener implements ServerListener {