showuon commented on code in PR #15476:
URL: https://github.com/apache/kafka/pull/15476#discussion_r1528195441
##########
core/src/test/scala/integration/kafka/admin/ListOffsetsIntegrationTest.scala:
##########
@@ -79,9 +79,34 @@ class ListOffsetsIntegrationTest extends
KafkaServerTestHarness {
@ParameterizedTest(name = TestInfoUtils.TestWithParameterizedQuorumName)
@ValueSource(strings = Array("zk", "kraft"))
- def testThreeRecordsInSeparateBatch(quorum: String): Unit = {
+ def testThreeNonCompressedRecordsInOneBatch(quorum: String): Unit = {
+ produceMessagesInOneBatch()
+ verifyListOffsets()
+
+ // test LogAppendTime case
+ val props: Properties = new Properties()
+ props.setProperty(TopicConfig.MESSAGE_TIMESTAMP_TYPE_CONFIG,
"LogAppendTime")
+ createTopicWithConfig(topicNameWithCustomConfigs, props)
+ produceMessagesInOneBatch(topic=topicNameWithCustomConfigs)
+ // In LogAppendTime's case, if the timestamps are the same, we choose the
offset of the first record
Review Comment:
These codes to verify the logAppendTime has duplicated quite a lot in this
test suite. Could we extract the into another method?
--
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]