jolshan commented on a change in pull request #9590:
URL: https://github.com/apache/kafka/pull/9590#discussion_r622355520



##########
File path: core/src/test/scala/unit/kafka/log/LogCleanerManagerTest.scala
##########
@@ -540,13 +540,34 @@ class LogCleanerManagerTest extends Logging {
 
     while(log.numberOfSegments < 8)
       log.appendAsLeader(records(log.logEndOffset.toInt, 
log.logEndOffset.toInt, time.milliseconds()), leaderEpoch = 0)
+    log.updateHighWatermark(log.activeSegment.baseOffset)
 
     val lastCleanOffset = Some(0L)
     val cleanableOffsets = LogCleanerManager.cleanableOffsets(log, 
lastCleanOffset, time.milliseconds)
     assertEquals(0L, cleanableOffsets.firstDirtyOffset, "The first cleanable 
offset starts at the beginning of the log.")
     assertEquals(log.activeSegment.baseOffset, 
cleanableOffsets.firstUncleanableDirtyOffset, "The first uncleanable offset 
begins with the active segment.")
   }
 
+  @Test
+  def testCleanableOffsetsForNoneWithLowerHighWatermark(): Unit = {

Review comment:
       I think the None may have been taken from the test above. In that test, 
it was referring to "no minimum compaction lag settings active". Changed name 
and added a comment to describe what the test is doing.




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

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to