Files
codex-mmo/evals/adaptive-change/holdout/tight-small-change/test_holdout_ledger.py
T
2026-08-24 08:11:59 -07:00

14 lines
399 B
Python

import unittest
from ledger import Ledger
class HoldoutLedgerTests(unittest.TestCase):
def test_multiple_rejections_do_not_consume_id(self):
ledger = Ledger()
for _ in range(2):
with self.assertRaises(ValueError):
ledger.apply("withdraw", "a", -2)
ledger.apply("fund", "a", 4)
self.assertEqual(ledger.apply("withdraw", "a", -2), 2)