-
Notifications
You must be signed in to change notification settings - Fork 2
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
Refine base tests #77
Conversation
This comment was marked as resolved.
This comment was marked as resolved.
6678282
to
43bb154
Compare
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 do we need both Constants
& Defaults
contracts? The variables in Defaults
are just duplicated
We can have only Constants
, wdyt? @smol-ninja
test: Add constructor test test: Use constants from Defaults contract test: Replace StdUtils with PRBMathUtils test: Replace StdAssertions with PRBMathAssertions test: inherit Defaults in Base contract test: remove redundant variables
a4532c4
to
f46739c
Compare
The idea was to have one contract for constants and one for default values. The values are not duplicated.
But since there are not many constants, we can merge them as well. But should we not call it |
you are correct, i was wrong
Yes, we could merge them, but I would prefer to call // deploy contract
Defaults internal defaults = new Defaults();
// call constant
defaults.MY_CONSTANT(); One disadvantage in having a separate contracts is that it makes debugging messier because you will have a lot of function calls in |
I agree thats why I made |
@smol-ninja I have squashed and rebased from, and merged |
LGTM. Thanks for review. Merging now. |
Changelogs
Constants
andTypes
contracts.Constants
is inherited byBase
.Modifers.sol