Skip to content

Commit f12fa5d

Browse files
committed
test: fix invalid operation assertion by using model_construct to bypass enum validation (Operation.REPLACE is valid so we can no longer use it in test_invalid_operation)
1 parent 070c885 commit f12fa5d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

tests/table/test_snapshots.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -398,8 +398,8 @@ def test_merge_snapshot_summaries_overwrite_summary() -> None:
398398

399399
def test_invalid_operation() -> None:
400400
with pytest.raises(ValueError) as e:
401-
update_snapshot_summaries(summary=Summary(Operation("invalid")))
402-
assert "Operation not implemented: Operation" in str(e.value)
401+
update_snapshot_summaries(summary=Summary.model_construct(operation="unknown_operation"))
402+
assert "Operation not implemented: unknown_operation" in str(e.value)
403403

404404

405405
def test_invalid_type() -> None:

0 commit comments

Comments
 (0)