bziobrowski commented on code in PR #14345:
URL: https://github.com/apache/pinot/pull/14345#discussion_r1908562307


##########
pinot-segment-local/src/test/java/org/apache/pinot/segment/local/indexsegment/mutable/MutableSegmentImplUpsertComparisonColTest.java:
##########
@@ -131,43 +146,55 @@ public void testUpsertOutOfOrderRecordColumn()
   public void testUpsertIngestion(UpsertConfig upsertConfig)
       throws Exception {
     setup(upsertConfig);
-    ImmutableRoaringBitmap bitmap = 
_mutableSegmentImpl.getValidDocIds().getMutableRoaringBitmap();
-    // note offset column is used for determining sequence but not time column
-    Assert.assertEquals(_mutableSegmentImpl.getNumDocsIndexed(), 4);
-    Assert.assertFalse(bitmap.contains(0));
-    Assert.assertTrue(bitmap.contains(1));
-    Assert.assertTrue(bitmap.contains(2));
-    Assert.assertFalse(bitmap.contains(3));
+    try {
+      ImmutableRoaringBitmap bitmap = 
_mutableSegmentImpl.getValidDocIds().getMutableRoaringBitmap();
+      // note offset column is used for determining sequence but not time 
column
+      Assert.assertEquals(_mutableSegmentImpl.getNumDocsIndexed(), 4);
+      Assert.assertFalse(bitmap.contains(0));
+      Assert.assertTrue(bitmap.contains(1));
+      Assert.assertTrue(bitmap.contains(2));
+      Assert.assertFalse(bitmap.contains(3));
+    } finally {
+      tearDown();

Review Comment:
   It 'is' possible but would require rewriting whole test . That is because 
`public void setup(UpsertConfig upsertConfig)` is called multiple times per 
test method, and each time allocates new resources. 



-- 
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: commits-unsubscr...@pinot.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org

Reply via email to