lucasbru commented on code in PR #17414:
URL: https://github.com/apache/kafka/pull/17414#discussion_r1809092349


##########
clients/src/test/java/org/apache/kafka/clients/consumer/internals/FetchCollectorTest.java:
##########
@@ -620,10 +645,49 @@ public void 
testCollectFetchInitializationOffsetOutOfRangeErrorWithOffsetReset()
         final Fetch<String, String> fetch = 
fetchCollector.collectFetch(fetchBuffer);
 
         assertTrue(fetch.isEmpty());
+        assertEquals(0, fetch.nextOffsets().size());
         
verify(subscriptions).requestOffsetResetIfPartitionAssigned(topicPartition0);
         verify(fetchBuffer).setNextInLineFetch(null);
     }
 
+    @Test
+    public void testReadCommittedWithAbortedTransaction() {
+        buildDependencies();

Review Comment:
   Where are you configuring the fetch collector to use read_committed mode? I 
think you somehow have to extend `buildDependencies` to actually do what you 
state in the test name. I debugged your unit test, and it indeed runs in 
read_uncommmitted mode. So I don't think it's testing what Andrew was asking 
for. Check out how `fetchConfig` is constructed.



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

Reply via email to