jsancio commented on code in PR #15671:
URL: https://github.com/apache/kafka/pull/15671#discussion_r1581322854


##########
core/src/test/scala/integration/kafka/server/RaftClusterSnapshotTest.scala:
##########
@@ -87,9 +85,12 @@ class RaftClusterSnapshotTest {
 
           // Check that we can read the entire snapshot
           while (snapshot.hasNext) {
-            val batch = snapshot.next()
+            val batch = snapshot.next
             assertTrue(batch.sizeInBytes > 0)
-            assertNotEquals(Collections.emptyList(), batch.records())
+            assertTrue(
+              batch.records.isEmpty != batch.controlRecords.isEmpty,

Review Comment:
   Yeah. I thought I was being creative when I discovered that invariant 😄 . I 
wrote a comment and changed it to use `assertNotEquals`. Let me know if that 
helps.



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

Reply via email to