-
Notifications
You must be signed in to change notification settings - Fork 46
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add basic dev test setup #59
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking good, thanks!!
I left some minor comments inline.
One more generic one, related to the deployment testing, I think we should look into this:
https://github.com/ChainSecurity/deployment_validation
(Do you remember? We watch the presentation about it in Paris)
pragma solidity 0.8.18; | ||
|
||
interface IGasPool { | ||
// empty |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Curious: why is this needed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm that was to be consistent with declaring interfaces in BaseTest then deploying in DevTestSetup. I've changed this so we just declare the contract GasPool in BaseTest rather than the interface (and deleted the interface). An empty interface is awkward.
contracts/src/test/deployment.t.sol
Outdated
|
||
// Active Pool | ||
|
||
function testActivePoolHasCorrectActivePoolAddress() public { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess the 2nd one should be Stability instead of Active
contracts/src/test/deployment.t.sol
Outdated
|
||
// Sorted Troves | ||
|
||
function testSortedTrovesHasCorrectTroveManagerAddress() public { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Name is mixed with the test below
Definitely, I like the idea of deployment validation. It's another layer of security assurance for users, and will be a good fit for Bold since the system won't be upgradeable. Assuming we use ChainSecurity for an audit we can discuss it with them. |
Add a basic dev environment test setup - deploying and connecting core contracts, using a testnet PriceFeed - to allow testing in Solidity with Foundry.