Fuzzed Premium Test
Closed this issue · 1 comments
dapp-whisperer commented
- Create a Cdp with a fuzzed ICR, within the range for a given category
- Calculate what we expect the premium to be from a full liquidation of that Cdp
- Attempt to fully liquidate the Cdp via
liquidate
andbatchLiquidate
(with a batch of just that Cdp)
Categories of Cdp:
- Cdps undercollateralized under minimum liq premium [<3% ICR] (expect all Coll as incentive, all debt redistributed)
- Cdps undercollateralized [3% < ICR < 100%] (expect 3% as incentive, all remaining debt redistributed)
- Cdps overcollateralized but liquidatable [100% <= ICR < 110%] (expect min(3%, 110%-ICR) as incentive, all remaining debt redistributed if below 103%)
- Cdps overcollateralized but liquidatable in recovery mode [110% <= ICR < 125%] (expect 10% as Incentive, no debt redistribution)