Closed wtj2021 closed 4 months ago
The recent updates focus on enhancing the functionality and integrity of the contract ecosystem, particularly around the management of stakes and collaterals. A new function has been introduced to calculate real stakes, and the interface now supports snapshots of total collaterals and stakes. TestContracts have been enriched with new variables and functions to ensure the robustness of stake and collateral calculations, alongside the introduction of invariant checks to maintain system properties.
Files | Change Summary |
---|---|
.../contracts/CRLens.sol .../contracts/Interfaces/ICdpManagerData.sol |
Added getRealStake function in CRLens contract;Introduced totalCollateralSnapshot() and totalStakesSnapshot() in ICdpManagerData interface. |
.../contracts/TestContracts/invariants/BeforeAfter.sol |
New variables for stake and collateral snapshots. |
.../contracts/TestContracts/invariants/Properties.sol |
New internal view functions for CDPM and CSP invariants. |
.../contracts/TestContracts/invariants/TargetFunctions.sol .../contracts/TestContracts/invariants/echidna/EchidnaProperties.sol |
Added _checkStakeInvariants() for stake checks;Added functions for CDPM invariants. |
🐇✨
In the land of code, where the smart contracts bloom,
A rabbit hopped in, avoiding the gloom.
With a flick and a click, new functions took flight,
Ensuring the stakes and collaterals just right.
"To integrity and beyond!" the rabbit did cheer,
With every line of code, the vision became clear.
🌟📜🚀
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
Job ID | caf59116-8525-49d0-98de-1de66cf017e6 |
Command | yarn && git submodule init && git submodule update && solc-select use 0.8.17 && cd packages/contracts/ && yarn echidna --test-mode assertion --test-limit 300000 |
Instance ID | i-0a50904cbda7d5bd3 |
Instance Type | c5.2xlarge |
Status | Started |
Elapsed |
Job ID | caf59116-8525-49d0-98de-1de66cf017e6 |
Command | yarn && git submodule init && git submodule update && solc-select use 0.8.17 && cd packages/contracts/ && yarn echidna --test-mode assertion --test-limit 300000 |
Instance ID | i-0a50904cbda7d5bd3 |
Instance Type | c5.2xlarge |
Status | Running |
Elapsed | 49 seconds |
Job ID | caf59116-8525-49d0-98de-1de66cf017e6 |
Command | yarn && git submodule init && git submodule update && solc-select use 0.8.17 && cd packages/contracts/ && yarn echidna --test-mode assertion --test-limit 300000 |
Instance ID | i-0a50904cbda7d5bd3 |
Instance Type | c5.2xlarge |
Status | Running |
Elapsed | 50 seconds |
Job ID | caf59116-8525-49d0-98de-1de66cf017e6 |
Command | yarn && git submodule init && git submodule update && solc-select use 0.8.17 && cd packages/contracts/ && yarn echidna --test-mode assertion --test-limit 300000 |
Instance ID | i-0a50904cbda7d5bd3 |
Instance Type | c5.2xlarge |
Status | Success |
Elapsed | 13 hours 4 minutes 13 seconds |
Summary by CodeRabbit
New Features
Tests