-
Notifications
You must be signed in to change notification settings - Fork 0
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
Feat/tests unit and fuzz #5
Conversation
@@ -486,8 +492,6 @@ abstract contract BaseStrategy is ERC4626, AccessControl { | |||
* @custom:requires INTEGRATOR_ROLE | |||
*/ | |||
function setVestingPeriod(uint64 newVestingPeriod) external onlyRole(INTEGRATOR_ROLE) { |
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.
why did we remove that?
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 thought it wasn't in our best interest to set boundaries for a vesting period
abi.encode(50e18) | ||
); | ||
uint256 maxRedeem = strategy.maxRedeem(alice); | ||
assertEq(maxRedeem, strategy.convertToShares(50e18)); |
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.
Instead of doing strategy.convertToShares(50e18)
can we compute the actual number, just to have at least one place where we do the actual computation
abi.encode(50e18) | ||
); | ||
uint256 maxWithdraw = strategy.maxWithdraw(alice); | ||
assertEq(maxWithdraw, 50e18); |
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.
It would be great also to have a test on the minimum of a user balance
); | ||
assertEq( | ||
strategy.maxMint(alice), | ||
115625846136565629368682392502753472473372881815114206356643976577531593328100 |
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.
type(uint256).max ?
No description provided.