Summary
The get_total_supply view should return the total keys in circulation for a specific creator, not a global count. Unit tests should confirm the supply is scoped correctly per creator and does not bleed across registrations.
Scope
- Register creator A, buy 10 keys — assert
get_total_supply(A) returns 10
- Register creator B, buy 5 keys — assert
get_total_supply(B) returns 5
- Assert
get_total_supply(A) still returns 10 after creator B's buy
- Sell 3 keys from creator A — assert
get_total_supply(A) returns 7
- Assert
get_total_supply for an unregistered creator panics with creator_not_found
Acceptance Criteria
ETA: 12 hours
Coordinate on Telegram
Summary
The
get_total_supplyview should return the total keys in circulation for a specific creator, not a global count. Unit tests should confirm the supply is scoped correctly per creator and does not bleed across registrations.Scope
get_total_supply(A)returns 10get_total_supply(B)returns 5get_total_supply(A)still returns 10 after creator B's buyget_total_supply(A)returns 7get_total_supplyfor an unregistered creator panics withcreator_not_foundAcceptance Criteria
creator_not_foundETA: 12 hours
Coordinate on Telegram