Skip to content

Commit 7f87949

Browse files
committed
add test
1 parent 0063ecb commit 7f87949

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

tests/table/test_init.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -204,6 +204,18 @@ def test_snapshot_by_id(table_v2: Table) -> None:
204204
)
205205

206206

207+
def test_snapshot_by_timestamp(table_v2: Table) -> None:
208+
assert table_v2.snapshot_by_timestamp(1555100955771) == Snapshot(
209+
snapshot_id=3055729675574597004,
210+
parent_snapshot_id=3051729675574597004,
211+
sequence_number=1,
212+
timestamp_ms=1555100955770,
213+
manifest_list="s3://a/b/2.avro",
214+
summary=Summary(operation=Operation.APPEND),
215+
schema_id=1,
216+
)
217+
218+
207219
def test_snapshot_by_id_does_not_exist(table_v2: Table) -> None:
208220
assert table_v2.snapshot_by_id(-1) is None
209221

0 commit comments

Comments
 (0)