Copilot commented on code in PR #63086:
URL: https://github.com/apache/doris/pull/63086#discussion_r3208521466


##########
be/test/storage/segment/variant_column_writer_reader_test.cpp:
##########
@@ -1538,29 +1538,7 @@ TEST_F(VariantColumnWriterReaderTest, 
test_read_doc_compact_from_doc_value_bucke
     st = variant_column_reader->new_iterator(&root_it, &parent_column, 
&storage_read_opts,
                                              &column_reader_cache);
     EXPECT_TRUE(st.ok()) << st.msg();
-    EXPECT_TRUE(dynamic_cast<HierarchicalDataIterator*>(root_it.get()) != 
nullptr);
-
-    ColumnIteratorOptions root_iter_opts;
-    root_iter_opts.stats = &stats;
-    root_iter_opts.file_reader = file_reader.get();
-    st = root_it->init(root_iter_opts);
-    EXPECT_TRUE(st.ok()) << st.msg();
-
-    MutableColumnPtr root_dst =
-            
ColumnVariant::create(parent_column.variant_max_subcolumns_count(), false);
-    size_t root_nrows = kRows;
-    st = root_it->seek_to_ordinal(0);
-    EXPECT_TRUE(st.ok()) << st.msg();
-    st = root_it->next_batch(&root_nrows, root_dst);
-    EXPECT_TRUE(st.ok()) << st.msg();
-    EXPECT_EQ(root_nrows, kRows);
-
-    for (int i = 0; i < kRows; ++i) {
-        std::string value;
-        assert_cast<ColumnVariant*>(root_dst.get())
-                ->serialize_one_row_to_string(i, &value, options);
-        EXPECT_EQ(value, inserted_jsonstr[i]);
-    }
+    EXPECT_TRUE(dynamic_cast<VariantRootColumnIterator*>(root_it.get()) != 
nullptr);
 

Review Comment:
   This test used to validate that reading the root Variant iterator in 
flat-leaf (compaction) mode returns the same JSON strings as were written, but 
now it only asserts the iterator type. Since this PR changes the root read 
plan/iterator selection, consider keeping at least a small data correctness 
check (e.g., init + read a few rows + compare to inserted_jsonstr) so 
regressions in ROOT_FLAT decoding won’t slip through.
   



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