diff --git a/e2e/tests/core/02-client/client_test.go b/e2e/tests/core/02-client/client_test.go index e31237e5ff4..1bb72b5409d 100644 --- a/e2e/tests/core/02-client/client_test.go +++ b/e2e/tests/core/02-client/client_test.go @@ -135,7 +135,7 @@ func (s *ClientTestSuite) TestClientUpdateProposal_Succeeds() { t.Run("pass client update proposal", func(t *testing.T) { proposal := clienttypes.NewClientUpdateProposal(ibctesting.Title, ibctesting.Description, subjectClientID, substituteClientID) - s.ExecuteGovProposal(ctx, chainA, chainAWallet, proposal) + s.ExecuteGovV1Beta1Proposal(ctx, chainA, chainAWallet, proposal) }) t.Run("check status of each client", func(t *testing.T) { @@ -286,7 +286,7 @@ func (s *ClientTestSuite) TestAllowedClientsParam() { s.Require().NotNil(authority) msg := clienttypes.NewMsgUpdateParams(authority.String(), clienttypes.NewParams(allowedClient)) - s.ExecuteGovProposalV1(ctx, msg, chainA, chainAWallet, 1) + s.ExecuteGovV1Proposal(ctx, msg, chainA, chainAWallet, 1) } else { value, err := tmjson.Marshal([]string{allowedClient}) s.Require().NoError(err) @@ -295,7 +295,7 @@ func (s *ClientTestSuite) TestAllowedClientsParam() { } proposal := paramsproposaltypes.NewParameterChangeProposal(ibctesting.Title, ibctesting.Description, changes) - s.ExecuteGovProposal(ctx, chainA, chainAWallet, proposal) + s.ExecuteGovV1Beta1Proposal(ctx, chainA, chainAWallet, proposal) } }) diff --git a/e2e/tests/core/03-connection/connection_test.go b/e2e/tests/core/03-connection/connection_test.go index 20fee4e830b..526c3f092c0 100644 --- a/e2e/tests/core/03-connection/connection_test.go +++ b/e2e/tests/core/03-connection/connection_test.go @@ -88,14 +88,14 @@ func (s *ConnectionTestSuite) TestMaxExpectedTimePerBlockParam() { s.Require().NotNil(authority) msg := connectiontypes.NewMsgUpdateParams(authority.String(), connectiontypes.NewParams(delay)) - s.ExecuteGovProposalV1(ctx, msg, chainA, chainAWallet, 1) + s.ExecuteGovV1Proposal(ctx, msg, chainA, chainAWallet, 1) } else { changes := []paramsproposaltypes.ParamChange{ paramsproposaltypes.NewParamChange(ibcexported.ModuleName, string(connectiontypes.KeyMaxExpectedTimePerBlock), fmt.Sprintf(`"%d"`, delay)), } proposal := paramsproposaltypes.NewParameterChangeProposal(ibctesting.Title, ibctesting.Description, changes) - s.ExecuteGovProposal(ctx, chainA, chainAWallet, proposal) + s.ExecuteGovV1Beta1Proposal(ctx, chainA, chainAWallet, proposal) } }) diff --git a/e2e/tests/interchain_accounts/gov_test.go b/e2e/tests/interchain_accounts/gov_test.go index 1213c2f49c0..ac6abfea000 100644 --- a/e2e/tests/interchain_accounts/gov_test.go +++ b/e2e/tests/interchain_accounts/gov_test.go @@ -52,7 +52,7 @@ func (s *InterchainAccountsGovTestSuite) TestInterchainAccountsGovIntegration() t.Run("execute proposal for MsgRegisterInterchainAccount", func(t *testing.T) { version := icatypes.NewDefaultMetadataString(ibctesting.FirstConnectionID, ibctesting.FirstConnectionID) msgRegisterAccount := controllertypes.NewMsgRegisterInterchainAccount(ibctesting.FirstConnectionID, govModuleAddress.String(), version) - s.ExecuteGovProposalV1(ctx, msgRegisterAccount, chainA, controllerAccount, 1) + s.ExecuteGovV1Proposal(ctx, msgRegisterAccount, chainA, controllerAccount, 1) }) t.Run("start relayer", func(t *testing.T) { @@ -102,7 +102,7 @@ func (s *InterchainAccountsGovTestSuite) TestInterchainAccountsGovIntegration() } msgSendTx := controllertypes.NewMsgSendTx(govModuleAddress.String(), ibctesting.FirstConnectionID, uint64(time.Hour.Nanoseconds()), packetData) - s.ExecuteGovProposalV1(ctx, msgSendTx, chainA, controllerAccount, 2) + s.ExecuteGovV1Proposal(ctx, msgSendTx, chainA, controllerAccount, 2) }) t.Run("verify tokens transferred", func(t *testing.T) { diff --git a/e2e/tests/interchain_accounts/params_test.go b/e2e/tests/interchain_accounts/params_test.go index 43c976ce0dd..37fba0c27f0 100644 --- a/e2e/tests/interchain_accounts/params_test.go +++ b/e2e/tests/interchain_accounts/params_test.go @@ -74,14 +74,14 @@ func (s *InterchainAccountsParamsTestSuite) TestControllerEnabledParam() { Signer: authority.String(), Params: controllertypes.NewParams(false), } - s.ExecuteGovProposalV1(ctx, &msg, chainA, controllerAccount, 1) + s.ExecuteGovV1Proposal(ctx, &msg, chainA, controllerAccount, 1) } else { changes := []paramsproposaltypes.ParamChange{ paramsproposaltypes.NewParamChange(controllertypes.StoreKey, string(controllertypes.KeyControllerEnabled), "false"), } proposal := paramsproposaltypes.NewParameterChangeProposal(ibctesting.Title, ibctesting.Description, changes) - s.ExecuteGovProposal(ctx, chainA, controllerAccount, proposal) + s.ExecuteGovV1Beta1Proposal(ctx, chainA, controllerAccount, proposal) } }) @@ -131,14 +131,14 @@ func (s *InterchainAccountsParamsTestSuite) TestHostEnabledParam() { Signer: authority.String(), Params: hosttypes.NewParams(false, []string{hosttypes.AllowAllHostMsgs}), } - s.ExecuteGovProposalV1(ctx, &msg, chainB, chainBUser, 1) + s.ExecuteGovV1Proposal(ctx, &msg, chainB, chainBUser, 1) } else { changes := []paramsproposaltypes.ParamChange{ paramsproposaltypes.NewParamChange(hosttypes.StoreKey, string(hosttypes.KeyHostEnabled), "false"), } proposal := paramsproposaltypes.NewParameterChangeProposal(ibctesting.Title, ibctesting.Description, changes) - s.ExecuteGovProposal(ctx, chainB, chainBUser, proposal) + s.ExecuteGovV1Beta1Proposal(ctx, chainB, chainBUser, proposal) } }) diff --git a/e2e/tests/transfer/base_test.go b/e2e/tests/transfer/base_test.go index 124abbb230a..f89e297108e 100644 --- a/e2e/tests/transfer/base_test.go +++ b/e2e/tests/transfer/base_test.go @@ -275,14 +275,14 @@ func (s *TransferTestSuite) TestSendEnabledParam() { t.Run("change send enabled parameter to disabled", func(t *testing.T) { if isSelfManagingParams { msg := transfertypes.NewMsgUpdateParams(govModuleAddress.String(), transfertypes.NewParams(false, true)) - s.ExecuteGovProposalV1(ctx, msg, chainA, chainAWallet, 1) + s.ExecuteGovV1Proposal(ctx, msg, chainA, chainAWallet, 1) } else { changes := []paramsproposaltypes.ParamChange{ paramsproposaltypes.NewParamChange(transfertypes.StoreKey, string(transfertypes.KeySendEnabled), "false"), } proposal := paramsproposaltypes.NewParameterChangeProposal(ibctesting.Title, ibctesting.Description, changes) - s.ExecuteGovProposal(ctx, chainA, chainAWallet, proposal) + s.ExecuteGovV1Beta1Proposal(ctx, chainA, chainAWallet, proposal) } }) @@ -366,14 +366,14 @@ func (s *TransferTestSuite) TestReceiveEnabledParam() { t.Run("change receive enabled parameter to disabled ", func(t *testing.T) { if isSelfManagingParams { msg := transfertypes.NewMsgUpdateParams(govModuleAddress.String(), transfertypes.NewParams(false, false)) - s.ExecuteGovProposalV1(ctx, msg, chainA, chainAWallet, 1) + s.ExecuteGovV1Proposal(ctx, msg, chainA, chainAWallet, 1) } else { changes := []paramsproposaltypes.ParamChange{ paramsproposaltypes.NewParamChange(transfertypes.StoreKey, string(transfertypes.KeyReceiveEnabled), "false"), } proposal := paramsproposaltypes.NewParameterChangeProposal(ibctesting.Title, ibctesting.Description, changes) - s.ExecuteGovProposal(ctx, chainA, chainAWallet, proposal) + s.ExecuteGovV1Beta1Proposal(ctx, chainA, chainAWallet, proposal) } }) diff --git a/e2e/tests/upgrades/upgrade_test.go b/e2e/tests/upgrades/upgrade_test.go index ad209e76d71..9362b139088 100644 --- a/e2e/tests/upgrades/upgrade_test.go +++ b/e2e/tests/upgrades/upgrade_test.go @@ -57,7 +57,7 @@ func (s *UpgradeTestSuite) UpgradeChain(ctx context.Context, chain *cosmos.Cosmo } upgradeProposal := upgradetypes.NewSoftwareUpgradeProposal(fmt.Sprintf("upgrade from %s to %s", currentVersion, upgradeVersion), "upgrade chain E2E test", plan) - s.ExecuteGovProposal(ctx, chain, wallet, upgradeProposal) + s.ExecuteGovV1Beta1Proposal(ctx, chain, wallet, upgradeProposal) height, err := chain.Height(ctx) s.Require().NoError(err, "error fetching height before upgrade") diff --git a/e2e/testsuite/grpc_query.go b/e2e/testsuite/grpc_query.go index 6353154831f..5b9e5b75fdf 100644 --- a/e2e/testsuite/grpc_query.go +++ b/e2e/testsuite/grpc_query.go @@ -244,8 +244,8 @@ func (s *E2ETestSuite) QueryCounterPartyPayee(ctx context.Context, chain ibc.Cha return res.CounterpartyPayee, nil } -// QueryProposal queries the governance proposal on the given chain with the given proposal ID. -func (s *E2ETestSuite) QueryProposal(ctx context.Context, chain ibc.Chain, proposalID uint64) (govtypesv1beta1.Proposal, error) { +// QueryProposalV1Beta1 queries the governance proposal on the given chain with the given proposal ID. +func (s *E2ETestSuite) QueryProposalV1Beta1(ctx context.Context, chain ibc.Chain, proposalID uint64) (govtypesv1beta1.Proposal, error) { queryClient := s.GetChainGRCPClients(chain).GovQueryClient res, err := queryClient.Proposal(ctx, &govtypesv1beta1.QueryProposalRequest{ ProposalId: proposalID, diff --git a/e2e/testsuite/tx.go b/e2e/testsuite/tx.go index 4e717b241c3..87b91e379a2 100644 --- a/e2e/testsuite/tx.go +++ b/e2e/testsuite/tx.go @@ -135,9 +135,9 @@ If this is a compatibility test, ensure that the fields are being sanitized in t return errorMsg } -// ExecuteGovProposalV1 submits a governance proposal using the provided user and message and uses all validators +// ExecuteGovV1Proposal submits a v1 governance proposal using the provided user and message and uses all validators // to vote yes on the proposal. It ensures the proposal successfully passes. -func (s *E2ETestSuite) ExecuteGovProposalV1(ctx context.Context, msg sdk.Msg, chain *cosmos.CosmosChain, user ibc.Wallet, proposalID uint64) { +func (s *E2ETestSuite) ExecuteGovV1Proposal(ctx context.Context, msg sdk.Msg, chain *cosmos.CosmosChain, user ibc.Wallet, proposalID uint64) { sender, err := sdk.AccAddressFromBech32(user.FormattedAddress()) s.Require().NoError(err) @@ -165,9 +165,9 @@ func (s *E2ETestSuite) ExecuteGovProposalV1(ctx context.Context, msg sdk.Msg, ch s.Require().Equal(govtypesv1.StatusPassed, proposal.Status) } -// ExecuteGovProposal submits the given governance proposal using the provided user and uses all validators to vote yes on the proposal. +// ExecuteGovV1Beta1Proposal submits the given v1beta1 governance proposal using the provided user and uses all validators to vote yes on the proposal. // It ensures the proposal successfully passes. -func (s *E2ETestSuite) ExecuteGovProposal(ctx context.Context, chain *cosmos.CosmosChain, user ibc.Wallet, content govtypesv1beta1.Content) { +func (s *E2ETestSuite) ExecuteGovV1Beta1Proposal(ctx context.Context, chain *cosmos.CosmosChain, user ibc.Wallet, content govtypesv1beta1.Content) { sender, err := sdk.AccAddressFromBech32(user.FormattedAddress()) s.Require().NoError(err) @@ -180,7 +180,7 @@ func (s *E2ETestSuite) ExecuteGovProposal(ctx context.Context, chain *cosmos.Cos // TODO: replace with parsed proposal ID from MsgSubmitProposalResponse // https://github.com/cosmos/ibc-go/issues/2122 - proposal, err := s.QueryProposal(ctx, chain, 1) + proposal, err := s.QueryProposalV1Beta1(ctx, chain, 1) s.Require().NoError(err) s.Require().Equal(govtypesv1beta1.StatusVotingPeriod, proposal.Status) @@ -188,13 +188,13 @@ func (s *E2ETestSuite) ExecuteGovProposal(ctx context.Context, chain *cosmos.Cos s.Require().NoError(err) // ensure voting period has not passed before validators finished voting - proposal, err = s.QueryProposal(ctx, chain, 1) + proposal, err = s.QueryProposalV1Beta1(ctx, chain, 1) s.Require().NoError(err) s.Require().Equal(govtypesv1beta1.StatusVotingPeriod, proposal.Status) time.Sleep(testvalues.VotingPeriod) // pass proposal - proposal, err = s.QueryProposal(ctx, chain, 1) + proposal, err = s.QueryProposalV1Beta1(ctx, chain, 1) s.Require().NoError(err) s.Require().Equal(govtypesv1beta1.StatusPassed, proposal.Status) }