-
Notifications
You must be signed in to change notification settings - Fork 362
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(tm2): Add additional unit tests for tm2/pkg/std #2739
base: master
Are you sure you want to change the base?
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #2739 +/- ##
==========================================
+ Coverage 60.87% 60.96% +0.09%
==========================================
Files 563 563
Lines 75193 75193
==========================================
+ Hits 45770 45845 +75
+ Misses 26055 25982 -73
+ Partials 3368 3366 -2
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
tm2/pkg/std/gasprice_test.go
Outdated
name string | ||
input string | ||
expected GasPrice | ||
hasError bool |
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.
better errorIs / errorContains
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.
tm2/pkg/std/gasprice_test.go
Outdated
name string | ||
input string | ||
expected []GasPrice | ||
hasError bool |
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.
same here
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.
tm2/pkg/std/tx_test.go
Outdated
} | ||
} | ||
|
||
func Test_CountSubKeys(t *testing.T) { |
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 underscore?
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.
tm2/pkg/std/tx_test.go
Outdated
signBytes, err := tx.GetSignBytes(chainID, accountNumber, sequence) | ||
require.NoError(t, err) | ||
require.NotEmpty(t, signBytes) |
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.
should be a golden test (match signBytes against a known example output)
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.
Add necessary unit tests to increase test coverage for this package
Contributors' checklist...
BREAKING CHANGE: xxx
message was included in the description