-
Notifications
You must be signed in to change notification settings - Fork 149
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
fix: integer overflow isuue for defaultMaxQueryPayment field #2213
fix: integer overflow isuue for defaultMaxQueryPayment field #2213
Conversation
Signed-off-by: svetoslav-nikol0v <[email protected]>
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## develop #2213 +/- ##
===========================================
+ Coverage 78.24% 84.48% +6.23%
===========================================
Files 266 305 +39
Lines 66766 76288 +9522
===========================================
+ Hits 52243 64453 +12210
+ Misses 14523 11835 -2688 ☔ View full report in Codecov by Sentry. |
|
||
it("should set defaultMaxQueryPayment field", async function () { | ||
this.timeout(120000); | ||
const value = new Hbar(100); |
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.
for the purpose of the test to demonstrate that can handle really large numbers I would suggest
const value = new Hbar(100); | |
const value = new Hbar(9223372036854775807); |
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.
We need pass this number in that way Long.fromString('9223372036854775807')
because is bigger than MAX_SAFE_INTEGER number.
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.
LGTM
Description:
Handles larger integer numbers when are set to
defaultMaxQueryPayment
field.Fixes #2203
Checklist