Skip to content
This repository has been archived by the owner on Aug 1, 2024. It is now read-only.

Commit

Permalink
Fix unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
misko9 committed Oct 24, 2023
1 parent 05a9647 commit a462188
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions x/igp/keeper/msg_server_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -613,7 +613,7 @@ func (suite *KeeperTestSuite) TestPayForGas() {
suite.Require().NoError(err)
suite.Require().Equal(quoteExpected, nativeTokensOwedResp.Amount)

coinExpected := nativeTokensOwedResp.Amount.String() + nativeTokensOwedResp.Denom
coinExpected := nativeTokensOwedResp.Amount.String()
paymentResp, err = suite.mockPayForGas(igpId, payer, testMessageId, testDestinationDomain, testGasAmount, maxPayment)

events := suite.ctx.EventManager().Events()
Expand All @@ -627,6 +627,7 @@ func (suite *KeeperTestSuite) TestPayForGas() {
sdk.NewAttribute(types.AttributeKeySender, payer),
sdk.NewAttribute(types.AttributeBeneficiary, igpBeneficiary),
sdk.NewAttribute(types.AttributePayment, coinExpected),
sdk.NewAttribute(types.AttributeIgpId, strconv.FormatUint(uint64(igpId), 10)),
),
sdk.NewEvent(
sdk.EventTypeMessage,
Expand Down Expand Up @@ -738,7 +739,7 @@ func (suite *KeeperTestSuite) TestDispatchPayProcess() {
suite.Require().NoError(err)
suite.Require().Equal(quoteExpected, nativeTokensOwedResp.Amount)

coinExpected := nativeTokensOwedResp.Amount.String() + nativeTokensOwedResp.Denom
coinExpected := nativeTokensOwedResp.Amount.String()
_, err = suite.mockPayForGas(igpId, payer, string(testMessageId), testDestinationDomain, testGasAmount, maxPayment)

suite.Require().Contains(suite.ctx.EventManager().Events(), sdk.NewEvent(
Expand All @@ -748,6 +749,7 @@ func (suite *KeeperTestSuite) TestDispatchPayProcess() {
sdk.NewAttribute(types.AttributeKeySender, payer),
sdk.NewAttribute(types.AttributeBeneficiary, igpBeneficiary),
sdk.NewAttribute(types.AttributePayment, coinExpected),
sdk.NewAttribute(types.AttributeIgpId, strconv.FormatUint(uint64(igpId), 10)),
))
})
}
Expand Down

0 comments on commit a462188

Please sign in to comment.