Re: [PR] KAFKA-15347: fix unit test [kafka]
mjsax merged PR #14947: URL: https://github.com/apache/kafka/pull/14947 -- 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
Re: [PR] KAFKA-15347: fix unit test [kafka]
mjsax commented on code in PR #14947: URL: https://github.com/apache/kafka/pull/14947#discussion_r1418059234 ## streams/src/test/java/org/apache/kafka/streams/state/internals/RocksDBVersionedStoreSegmentValueFormatterTest.java: ## @@ -230,13 +230,19 @@ public void shouldFindAll() { segmentValue.findAll(testCase.records.get(testCase.records.size() - 1).timestamp, testCase.records.get(0).timestamp); int i = 0; +int index = 0; for (final TestRecord expectedRecord : testCase.records) { -final long expectedValidTo = i == 0 ? testCase.nextTimestamp : testCase.records.get(i - 1).timestamp; -assertThat(results.get(i).index(), equalTo(i)); +if (expectedRecord.value == null) { // should not return tombstones +index++; +continue; +} +final long expectedValidTo = index== 0 ? testCase.nextTimestamp : testCase.records.get(index - 1).timestamp; Review Comment: ```suggestion final long expectedValidTo = index == 0 ? testCase.nextTimestamp : testCase.records.get(index - 1).timestamp; ``` -- 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
[PR] KAFKA-15347: fix unit test [kafka]
aliehsaeedii opened a new pull request, #14947: URL: https://github.com/apache/kafka/pull/14947 *More detailed description of your change, if necessary. The PR title and PR message become the squashed commit message, so use a separate comment to ping reviewers.* *Summary of testing strategy (including rationale) for the feature or bug fix. Unit and/or integration tests are expected for any behaviour change and system tests should be considered for larger changes.* ### Committer Checklist (excluded from commit message) - [ ] Verify design and implementation - [ ] Verify test coverage and CI build status - [ ] Verify documentation (including upgrade notes) -- 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