Skip to content

Commit e9d320b

Browse files
committed
test: cover negative infinite ledger amounts
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
1 parent 72c693b commit e9d320b

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

‎Server/tests/test_overseer_ledger.py‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -126,6 +126,8 @@ def test_rejects_non_finite_or_naive_timestamps(ledger):
126126
ledger.record(category="cost", event_type="x", team_id="t", agent_id="a", amount=float("nan"))
127127
with pytest.raises(ValueError, match="finite"):
128128
ledger.record(category="cost", event_type="x", team_id="t", agent_id="a", amount=float("inf"))
129+
with pytest.raises(ValueError, match="finite"):
130+
ledger.record(category="cost", event_type="x", team_id="t", agent_id="a", amount=float("-inf"))
129131
with pytest.raises(ValueError, match="timezone-aware"):
130132
ledger.record(
131133
category="activity",

0 commit comments

Comments
 (0)