Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/iceberg/snapshot.cc
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,7 @@ bool Snapshot::Equals(const Snapshot& other) const {
return snapshot_id == other.snapshot_id &&
parent_snapshot_id == other.parent_snapshot_id &&
sequence_number == other.sequence_number && timestamp_ms == other.timestamp_ms &&
manifest_list == other.manifest_list && summary == other.summary &&
schema_id == other.schema_id && first_row_id == other.first_row_id &&
added_rows == other.added_rows;
}
Expand Down
8 changes: 8 additions & 0 deletions src/iceberg/test/snapshot_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,16 @@ TEST_F(SnapshotTest, EqualityComparison) {
Snapshot snapshot3(67890, {}, 1, TimePointMsFromUnixMs(1615569200000),
"s3://example/manifest_list.avro", summary3, {});

Snapshot snapshot4(12345, {}, 1, TimePointMsFromUnixMs(1615569200000),
"s3://example/other_manifest_list.avro", summary1, {});

Snapshot snapshot5(12345, {}, 1, TimePointMsFromUnixMs(1615569200000),
"s3://example/manifest_list.avro", summary3, {});

EXPECT_EQ(snapshot1, snapshot2);
EXPECT_NE(snapshot1, snapshot3);
EXPECT_NE(snapshot1, snapshot4);
EXPECT_NE(snapshot1, snapshot5);
}

} // namespace iceberg
Loading