Skip to content

Commit 1e6af48

Browse files
remove spurious TestABCICodeDeterminism tests (cosmos#1695)
## Description Thanks @colin-axner for noticing this. closes: #XXXX --- Before we can merge this PR, please make sure that all the following items have been checked off. If any of the checklist items are not applicable, please leave them but write a little note why. - [x] Targeted PR against correct branch (see [CONTRIBUTING.md](https://github.com/cosmos/ibc-go/blob/master/CONTRIBUTING.md#pr-targeting)) - [ ] Linked to Github issue with discussion and accepted design OR link to spec that describes this work. - [ ] Code follows the [module structure standards](https://github.com/cosmos/cosmos-sdk/blob/master/docs/building-modules/structure.md). - [ ] Wrote unit and integration [tests](https://github.com/cosmos/ibc-go/blob/master/CONTRIBUTING.md#testing) - [ ] Updated relevant documentation (`docs/`) or specification (`x/<module>/spec/`) - [ ] Added relevant `godoc` [comments](https://blog.golang.org/godoc-documenting-go-code). - [ ] Added a relevant changelog entry to the `Unreleased` section in `CHANGELOG.md` - [x] Re-reviewed `Files changed` in the Github PR explorer - [ ] Review `Codecov Report` in the comment section below once CI passes
1 parent ef4eaf9 commit 1e6af48

2 files changed

Lines changed: 0 additions & 144 deletions

File tree

modules/apps/27-interchain-accounts/host/ibc_module_test.go

Lines changed: 0 additions & 63 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,7 @@ import (
99
capabilitytypes "github.com/cosmos/cosmos-sdk/x/capability/types"
1010
"github.com/gogo/protobuf/proto"
1111
"github.com/stretchr/testify/suite"
12-
abcitypes "github.com/tendermint/tendermint/abci/types"
1312
"github.com/tendermint/tendermint/crypto"
14-
tmprotostate "github.com/tendermint/tendermint/proto/tendermint/state"
15-
tmstate "github.com/tendermint/tendermint/state"
1613

1714
"github.com/cosmos/ibc-go/v4/modules/apps/27-interchain-accounts/host/types"
1815
icatypes "github.com/cosmos/ibc-go/v4/modules/apps/27-interchain-accounts/types"
@@ -692,63 +689,3 @@ func (suite *InterchainAccountsTestSuite) TestControlAccountAfterChannelClose()
692689
hasBalance = suite.chainB.GetSimApp().BankKeeper.HasBalance(suite.chainB.GetContext(), icaAddr, sdk.Coin{Denom: sdk.DefaultBondDenom, Amount: sdk.NewInt(0)})
693690
suite.Require().True(hasBalance)
694691
}
695-
696-
// The safety of including SDK MsgResponses in the acknowledgement rests
697-
// on the inclusion of the abcitypes.ResponseDeliverTx.Data in the
698-
// abcitypes.ResposneDeliverTx hash. If the abcitypes.ResponseDeliverTx.Data
699-
// gets removed from consensus they must no longer be used in the packet
700-
// acknowledgement.
701-
//
702-
// This test acts as an indicator that the abcitypes.ResponseDeliverTx.Data
703-
// may no longer be deterministic.
704-
func (suite *InterchainAccountsTestSuite) TestABCICodeDeterminism() {
705-
msgResponseBz, err := proto.Marshal(&channeltypes.MsgChannelOpenInitResponse{})
706-
suite.Require().NoError(err)
707-
708-
msgData := &sdk.MsgData{
709-
MsgType: sdk.MsgTypeURL(&channeltypes.MsgChannelOpenInit{}),
710-
Data: msgResponseBz,
711-
}
712-
713-
txResponse, err := proto.Marshal(&sdk.TxMsgData{
714-
Data: []*sdk.MsgData{msgData},
715-
})
716-
suite.Require().NoError(err)
717-
718-
deliverTx := abcitypes.ResponseDeliverTx{
719-
Data: txResponse,
720-
}
721-
responses := tmprotostate.ABCIResponses{
722-
DeliverTxs: []*abcitypes.ResponseDeliverTx{
723-
&deliverTx,
724-
},
725-
}
726-
727-
differentMsgResponseBz, err := proto.Marshal(&channeltypes.MsgRecvPacketResponse{})
728-
suite.Require().NoError(err)
729-
730-
differentMsgData := &sdk.MsgData{
731-
MsgType: sdk.MsgTypeURL(&channeltypes.MsgRecvPacket{}),
732-
Data: differentMsgResponseBz,
733-
}
734-
735-
differentTxResponse, err := proto.Marshal(&sdk.TxMsgData{
736-
Data: []*sdk.MsgData{differentMsgData},
737-
})
738-
suite.Require().NoError(err)
739-
740-
differentDeliverTx := abcitypes.ResponseDeliverTx{
741-
Data: differentTxResponse,
742-
}
743-
744-
differentResponses := tmprotostate.ABCIResponses{
745-
DeliverTxs: []*abcitypes.ResponseDeliverTx{
746-
&differentDeliverTx,
747-
},
748-
}
749-
750-
hash := tmstate.ABCIResponsesResultsHash(&responses)
751-
differentHash := tmstate.ABCIResponsesResultsHash(&differentResponses)
752-
753-
suite.Require().NotEqual(hash, differentHash)
754-
}

modules/apps/27-interchain-accounts/host/types/ack_test.go

Lines changed: 0 additions & 81 deletions
This file was deleted.

0 commit comments

Comments
 (0)