majialoong commented on code in PR #22328:
URL: https://github.com/apache/kafka/pull/22328#discussion_r3522452099
##########
storage/src/test/java/org/apache/kafka/server/log/remote/metadata/storage/ConsumerTaskTest.java:
##########
@@ -104,6 +112,20 @@ public void testCloseOnNoAssignment() {
assertDoesNotThrow(() -> consumerTask.closeConsumer(), "CloseConsumer
method threw exception");
}
+ @Test
+ public void testCloseBeforeAssignmentDoesNotPollConsumer() {
+ final Consumer<byte[], byte[]> mockConsumer = mock(Consumer.class);
+ when(mockConsumer.poll(any(Duration.class)))
Review Comment:
Good catch, it was redundant with the `verify(..., never())` below. Removed,
Thanks!
--
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]