Use commitSync to check connection failure in listener update test
The use of consumer.poll() made the test flaky since in some cases, it doesn't wait for coordinator connection.
Reviewers: Manikumar Reddy
@@ -1315,7 +1315,7 @@ class DynamicBrokerReconfigurationTest extends ZooKeeperTestHarness with SaslSet
executors += executor
val future = executor.submit(new Runnable() {
def run() {
- assertEquals(0, consumer.poll(100).count)
+ consumer.commitSync()
}
})
verifyTimeout(future)
