From 8f1584cc669be2f17d25c0f467e136baeab75e60 Mon Sep 17 00:00:00 2001 From: Pino' Surace Date: Tue, 4 Apr 2023 15:07:43 +0200 Subject: [PATCH] fix conflicts --- x/wasm/keeper/relay.go | 4 ---- x/wasm/relay_test.go | 17 +++-------------- 2 files changed, 3 insertions(+), 18 deletions(-) diff --git a/x/wasm/keeper/relay.go b/x/wasm/keeper/relay.go index be743c0e05..f8450e3461 100644 --- a/x/wasm/keeper/relay.go +++ b/x/wasm/keeper/relay.go @@ -130,11 +130,7 @@ func (k Keeper) OnRecvPacket( res, gasUsed, execErr := k.wasmVM.IBCPacketReceive(codeInfo.CodeHash, env, msg, prefixStore, cosmwasmAPI, querier, ctx.GasMeter(), gas, costJSONDeserialization) k.consumeRuntimeGas(ctx, gasUsed) if execErr != nil { -<<<<<<< HEAD - return nil, sdkerrors.Wrap(types.ErrExecuteFailed, execErr.Error()) -======= panic(execErr) ->>>>>>> 5edfd6c (Update OnRecvPacket method to panic when an error is returned (#1298)) } if res.Err != "" { // handle error case as before https://github.com/CosmWasm/wasmvm/commit/c300106fe5c9426a495f8e10821e00a9330c56c6 return nil, sdkerrors.Wrap(types.ErrExecuteFailed, res.Err) diff --git a/x/wasm/relay_test.go b/x/wasm/relay_test.go index b3ecf36eaf..19be8b968e 100644 --- a/x/wasm/relay_test.go +++ b/x/wasm/relay_test.go @@ -31,20 +31,13 @@ func TestFromIBCTransferToContract(t *testing.T) { transferAmount := sdk.NewInt(1) specs := map[string]struct { -<<<<<<< HEAD - contract wasmtesting.IBCContractCallbacks - setupContract func(t *testing.T, contract wasmtesting.IBCContractCallbacks, chain *wasmibctesting.TestChain) - expChainABalanceDiff sdk.Int - expChainBBalanceDiff sdk.Int -======= contract wasmtesting.IBCContractCallbacks setupContract func(t *testing.T, contract wasmtesting.IBCContractCallbacks, chain *wasmibctesting.TestChain) expChainAPendingSendPackets int expChainBPendingSendPackets int - expChainABalanceDiff math.Int - expChainBBalanceDiff math.Int + expChainABalanceDiff sdk.Int + expChainBBalanceDiff sdk.Int expErr bool ->>>>>>> 5edfd6c (Update OnRecvPacket method to panic when an error is returned (#1298)) }{ "ack": { contract: &ackReceiverContract{}, @@ -117,12 +110,8 @@ func TestFromIBCTransferToContract(t *testing.T) { // when transfer via sdk transfer from A (module) -> B (contract) coinToSendToB := sdk.NewCoin(sdk.DefaultBondDenom, transferAmount) timeoutHeight := clienttypes.NewHeight(1, 110) -<<<<<<< HEAD - msg := ibctransfertypes.NewMsgTransfer(path.EndpointA.ChannelConfig.PortID, path.EndpointA.ChannelID, coinToSendToB, chainA.SenderAccount.GetAddress().String(), chainB.SenderAccount.GetAddress().String(), timeoutHeight, 0) -======= - msg := ibctransfertypes.NewMsgTransfer(path.EndpointA.ChannelConfig.PortID, path.EndpointA.ChannelID, coinToSendToB, chainA.SenderAccount.GetAddress().String(), chainB.SenderAccount.GetAddress().String(), timeoutHeight, 0, "") ->>>>>>> 5edfd6c (Update OnRecvPacket method to panic when an error is returned (#1298)) + msg := ibctransfertypes.NewMsgTransfer(path.EndpointA.ChannelConfig.PortID, path.EndpointA.ChannelID, coinToSendToB, chainA.SenderAccount.GetAddress().String(), chainB.SenderAccount.GetAddress().String(), timeoutHeight, 0) _, err := chainA.SendMsgs(msg) require.NoError(t, err) require.NoError(t, path.EndpointB.UpdateClient())