You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@geode.apache.org by GitBox <gi...@apache.org> on 2022/04/14 20:24:29 UTC

[GitHub] [geode] jdeppe-pivotal commented on a diff in pull request #7592: GEODE-10223: Fix BlockingCommandListnerTest to be less flaky.

jdeppe-pivotal commented on code in PR #7592:
URL: https://github.com/apache/geode/pull/7592#discussion_r850778592


##########
geode-for-redis/src/integrationTest/java/org/apache/geode/redis/internal/eventing/BlockingCommandListenerTest.java:
##########
@@ -58,7 +58,7 @@ public void testTimeoutIsAdjusted() {
     verify(context, times(1)).resubmitCommand(argumentCaptor.capture());
 
     double timeout = Coder.bytesToDouble(argumentCaptor.getValue().getCommandArguments().get(0));
-    assertThat(timeout).isLessThan(1.0D);
+    await().untilAsserted(() -> assertThat(timeout).isLessThan(1.0D));

Review Comment:
   Since `timeout` is only calculated once, this await will not do what you want. I think you're better off just putting a sleep before the `resubmitCommand()` call.
   



-- 
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: notifications-unsubscribe@geode.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org