Budget Governor.Test
Path:
loom-sprint-scaffold/loom/tests/execution/budget-governor.test.tsRelative: loom/tests/execution/budget-governor.test.tsSubproject: loom-sprint-scaffoldCategory: testsLines: 190Bytes: 6,388Imports: 3Exports: 0has tests
Content Preview
- /**
- * Tests for budget-governor (H3.6).
- *
- * Proves:
- * - all 3 hard cap types (calls, tokens, wallclock) are enforced
- * - calls breach at b_calls threshold
- * - tokens breach at b_tokens threshold
- * - wallclock breach at b_wallclock_s threshold
- * - recordCall correctly increments counters
- * - makeBudgetMemoryRecord creates valid state-summary record
- * - makeBudgetBreachEvent has correct shape
- * - Never kills mid-action (check at safe points only)
- */
- import { describe, expect, test } fr