-
Notifications
You must be signed in to change notification settings - Fork 735
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
test: add fee test with wrong denom order #3493
base: main
Are you sure you want to change the base?
Conversation
tests/e2e/e2e_test.go
Outdated
@@ -86,7 +91,40 @@ func (s *IntegrationTestSuite) TestSlashing() { | |||
s.testSlashing(chainAPI) | |||
} | |||
|
|||
// todo add fee test with wrong denom order | |||
func (s *IntegrationTestSuite) TestFeeWithWrongDenomOrder() { |
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.
Looks good. Can you move this to be a function in e2e_bank_test.go
and invoke it from within the TestBank
function?
tests/e2e/e2e_test.go
Outdated
// The transaction should still be accepted and processed correctly | ||
// despite the fees being in a different order | ||
tx, err := s.chainA.SignAndBroadcastTx(val1.keyInfo, txBuilder) | ||
s.Require().NoError(err) | ||
s.Require().Equal(uint32(0), tx.Code) |
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.
Would be good to use a require.Eventually
block like in
gaia/tests/e2e/e2e_bank_test.go
Line 40 in accd997
s.Require().Eventually( |
Hey @Eric-Warehime, I've addressed your review comments:
|
Your test is failing and not passing lint. |
|
Add test to verify that transactions with fees in non-standard denomination order are processed correctly.
This ensures that the chain is resilient to different orderings of fee denominations in transactions.
The test creates a transaction with fees ordered as "stake" then "atom" and verifies successful processing.