Area
Investment Vault / Testing
Complexity
Medium
File(s)
investment_vault/src/lib.rs:1484-1619
Problem
grep -n carbon investment_vault/src/test.rs returns exactly one hit — a negative-auth check on set_carbon_oracle. calculate_carbon_credits, issue_carbon_credits, transfer_carbon_credits, and carbon_credit_balance (the functions actually moving/crediting value) have zero tests, including no test for the "insufficient carbon credits" panic path in transfer_carbon_credits (line ~1590).
Scope
In:
- Unit tests for calculation correctness, issuance, transfer (success + insufficient-balance panic), and balance queries.
Out:
- Fixing the missing-auth bug itself (tracked in a separate issue).
Acceptance Criteria
Area
Investment Vault / Testing
Complexity
Medium
File(s)
investment_vault/src/lib.rs:1484-1619
Problem
grep -n carbon investment_vault/src/test.rsreturns exactly one hit — a negative-auth check on set_carbon_oracle. calculate_carbon_credits, issue_carbon_credits, transfer_carbon_credits, and carbon_credit_balance (the functions actually moving/crediting value) have zero tests, including no test for the "insufficient carbon credits" panic path in transfer_carbon_credits (line ~1590).Scope
In:
Out:
Acceptance Criteria