File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -42,7 +42,7 @@ def test_cannot_expire_protected_head_snapshot(table_v2: Table) -> None:
4242 assert any (ref .snapshot_id == HEAD_SNAPSHOT for ref in table_v2 .metadata .refs .values ())
4343
4444 # Attempt to expire the HEAD snapshot and expect a ValueError
45- with pytest .raises (ValueError , match = f"Cannot expire snapshot { HEAD_SNAPSHOT } as it is referenced by a branch or tag ." ):
45+ with pytest .raises (ValueError , match = f"Snapshot with ID { HEAD_SNAPSHOT } is protected and cannot be expired ." ):
4646 table_v2 .maintenance .expire_snapshots ().by_id (HEAD_SNAPSHOT ).commit ()
4747
4848 table_v2 .catalog .commit_table .assert_not_called ()
@@ -65,7 +65,7 @@ def test_cannot_expire_tagged_snapshot(table_v2: Table) -> None:
6565 )
6666 assert any (ref .snapshot_id == TAGGED_SNAPSHOT for ref in table_v2 .metadata .refs .values ())
6767
68- with pytest .raises (ValueError , match = f"Cannot expire snapshot { TAGGED_SNAPSHOT } as it is referenced by a branch or tag ." ):
68+ with pytest .raises (ValueError , match = f"Snapshot with ID { TAGGED_SNAPSHOT } is protected and cannot be expired ." ):
6969 table_v2 .maintenance .expire_snapshots ().by_id (TAGGED_SNAPSHOT ).commit ()
7070
7171 table_v2 .catalog .commit_table .assert_not_called ()
You can’t perform that action at this time.
0 commit comments