dajac commented on a change in pull request #9778:
URL: https://github.com/apache/kafka/pull/9778#discussion_r551298159



##########
File path: core/src/test/scala/unit/kafka/server/ClientQuotasRequestTest.scala
##########
@@ -212,7 +214,9 @@ class ClientQuotasRequestTest extends BaseRequestTest {
           InetAddress.getByName(unknownHost)
         else
           InetAddress.getByName(entityName)
-        assertEquals(expectedMatches(entity), 
servers.head.socketServer.connectionQuotas.connectionRateForIp(entityIp), 0.01)
+        TestUtils.waitUntilTrue(
+          () => expectedMatches(entity) - 
servers.head.socketServer.connectionQuotas.connectionRateForIp(entityIp) < 0.01
+          ,"Broker didn't update quotas from Zookeeper")

Review comment:
       * We usually put the `,` at the end of the previous line when we break a 
line.
   * Could we add the expected value and the current value in the message? We 
could say something like `Expected connection quota $expected for $entity, got 
$actual.`




----------------------------------------------------------------
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.

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


Reply via email to