coltmcnealy-lh commented on code in PR #17527:
URL: https://github.com/apache/kafka/pull/17527#discussion_r1805583386
##########
clients/src/test/java/org/apache/kafka/clients/MockClient.java:
##########
@@ -336,6 +336,12 @@ public List<ClientResponse> poll(long timeoutMs, long now)
{
copy.add(response);
}
+ if (copy.isEmpty()) {
+ // Simulate time advancing. If no responses are received, then we
know that
+ // we waited for the whole timeoutMs.
+ time.sleep(timeoutMs);
Review Comment:
I noticed when developing my test that repeated calls to `poll()` with
`timeoutMs == 10` never resulted in `time.milliseconds()` advancing, so the
fictitious `Node` in my test never became ready (time never advanced past the
throttled time). That's why I made this change; however, it broke all sorts of
things.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]