Skip to content

Commit

Permalink
fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
skosito committed Oct 17, 2024
1 parent ce3df52 commit d7fb759
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 7 deletions.
8 changes: 4 additions & 4 deletions e2e/e2etests/test_v2_erc20_withdraw_and_call.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@ func TestV2ERC20WithdrawAndCall(r *runner.E2ERunner, _ []string) {
r.ZEVMAuth.GasLimit = previousGasLimit
}()

// called with 0 amount since onCall implementation is for TestDappV2 is simple and generic without decoding the payload and amount handling for erc20
// and purpose of test is to verify that onCall is called with correct sender and payload
amount := big.NewInt(0)
// called with fixed amount without arg since onCall implementation is for TestDappV2 is simple and generic
// without decoding the payload and amount handling for erc20, purpose of test is to verify correct sender and payload are used
amount := big.NewInt(10000)

r.AssertTestDAppEVMCalled(false, payloadMessageWithdrawAuthenticatedCallERC20, amount)

Expand All @@ -43,7 +43,7 @@ func TestV2ERC20WithdrawAndCall(r *runner.E2ERunner, _ []string) {
r.Logger.CCTX(*cctx, "withdraw")
require.Equal(r, crosschaintypes.CctxStatus_OutboundMined, cctx.CctxStatus.Status)

r.AssertTestDAppEVMCalled(true, payloadMessageWithdrawAuthenticatedCallERC20, amount)
r.AssertTestDAppEVMCalled(true, payloadMessageWithdrawAuthenticatedCallERC20, big.NewInt(0))

// check expected sender was used
senderForMsg, err := r.TestDAppV2EVM.SenderWithMessage(
Expand Down
Loading

0 comments on commit d7fb759

Please sign in to comment.