AmatyaAvadhanula commented on code in PR #15379:
URL: https://github.com/apache/druid/pull/15379#discussion_r1396684066


##########
server/src/test/java/org/apache/druid/metadata/IndexerSQLMetadataStorageCoordinatorTest.java:
##########
@@ -2907,6 +2909,79 @@ public void 
testRetrieveUsedSegmentsAndCreatedDatesFetchesEternityForAnyInterval
     Assert.assertEquals(3, resultForEternity.size());
   }
 
+  @Test
+  public void testTimelineWithTombstoneCorePartitionsAs0() throws IOException
+  {
+    final Interval interval = Intervals.of("2020/2021");
+    // Create and commit a tombstone segment
+    final DataSegment tombstoneSegment = createSegment(
+        interval,
+        "version",
+        new TombstoneShardSpec()
+    );
+
+    final Set<DataSegment> tombstones = new 
HashSet<>(Collections.singleton(tombstoneSegment));
+    
Assert.assertTrue(coordinator.commitSegments(tombstones).containsAll(tombstones));
+
+    // Create and commit a data segment
+    final DataSegment dataSegment = createSegment(

Review Comment:
   I think it may be sufficient to have just one test which allocates and 
commits a segment using the methods in IndexerSqlMetadataStorageCoordinator. 
The test would succeed with the changes in the PR and fail without them
   



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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to