HeartLinked commented on code in PR #175:
URL: https://github.com/apache/iceberg-cpp/pull/175#discussion_r2281961576
##########
test/manifest_reader_test.cc:
##########
@@ -115,7 +116,88 @@ TEST_F(ManifestReaderTest, BasicTest) {
auto read_result = manifest_reader->Entries();
ASSERT_EQ(read_result.has_value(), true) << read_result.error().message;
- auto expected_entries = prepare_manifest_entries();
+ auto expected_entries = PrepareV1ManifestEntries();
+ ASSERT_EQ(read_result.value(), expected_entries);
+}
+
+class ManifestReaderV2Test : public TempFileTestBase {
+ protected:
+ static void SetUpTestSuite() { avro::AvroReader::Register(); }
+
+ void SetUp() override {
+ TempFileTestBase::SetUp();
+ local_fs_ = std::make_shared<::arrow::fs::LocalFileSystem>();
+ file_io_ =
std::make_shared<iceberg::arrow::ArrowFileSystemFileIO>(local_fs_);
+
+ avro::RegisterLogicalTypes();
+ }
+
+ std::vector<ManifestEntry> prepareV2NonPartitionedManifestEntries() {
+ std::vector<ManifestEntry> manifest_entries;
+ std::string test_dir_prefix =
"/tmp/db/db/v2_manifest_non_partitioned/data/";
Review Comment:
The path in the previous test code was exactly like this (as seen in this
commit: [Commit 043701c
](https://github.com/apache/iceberg-cpp/commit/043701c14d6015ffe3ec682b6fec886ba810b4d8#diff-6432ba44184f2025b3037c028b74b589b3ee8ccebffd5a003a037827cf7f70fa)
Therefore, I decided to maintain consistency with it and adopted the same path
specification when generating the test file. I don't consider this to be an
explicit error—for the purpose of testing, it meets the expected requirements.
--
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]