jeffkbkim commented on code in PR #13870: URL: https://github.com/apache/kafka/pull/13870#discussion_r1264075041
########## group-coordinator/src/test/java/org/apache/kafka/coordinator/group/GroupMetadataManagerTest.java: ########## @@ -376,19 +448,28 @@ public CoordinatorResult<ConsumerGroupHeartbeatResponseData, Record> consumerGro return result; } - public List<MockCoordinatorTimer.ExpiredTimeout<Record>> sleep(long ms) { + public List<ExpiredTimeout<Void, Record>> sleep(long ms) { time.sleep(ms); - List<MockCoordinatorTimer.ExpiredTimeout<Record>> timeouts = timer.poll(); - timeouts.forEach(timeout -> timeout.records.forEach(this::replay)); + List<ExpiredTimeout<Void, Record>> timeouts = timer.poll(); + timeouts.forEach(timeout -> { + if (timeout.result.replayRecords()) { + timeout.result.records().forEach(this::replay); + } + }); return timeouts; } - public MockCoordinatorTimer.ScheduledTimeout<Record> assertSessionTimeout( + public void sleepAndAssertEmptyResult(long ms) { + List<ExpiredTimeout<Void, Record>> timeouts = sleep(ms); + timeouts.forEach(timeout -> assertEquals(EMPTY_RESULT, timeout.result)); + } Review Comment: will keep it as assertEmptyResult as the timeout is not empty (can be) but we want to assert that the coordinator result is. -- 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: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org