Telegram (ask questions / claim the issue here first): https://t.me/+DOylgFv1jyJlNzM0
Why this matters
calculate_claimable uses checked_sub(...).unwrap_or_default() at lib.rs:347-350 to defend against withdrawn_amount > deposited_amount. The fuzz test that calls calculate_claimable directly only generates withdrawn = seed % (deposited+1), so withdrawn never exceeds deposited and the underflow-to-0 fallback is dead in tests.
Acceptance criteria
Files to touch
contracts/stream_contract/src/test.rs
contracts/stream_contract/src/lib.rs
Out of scope
- The rate*elapsed overflow cap (already covered)
Why this matters
calculate_claimable uses checked_sub(...).unwrap_or_default() at lib.rs:347-350 to defend against withdrawn_amount > deposited_amount. The fuzz test that calls calculate_claimable directly only generates withdrawn = seed % (deposited+1), so withdrawn never exceeds deposited and the underflow-to-0 fallback is dead in tests.
Acceptance criteria
Files to touch
contracts/stream_contract/src/test.rscontracts/stream_contract/src/lib.rsOut of scope