From 2f7a71e153ea8770339b47b92d89d1eed19f29b5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Colin=20Axn=C3=A9r?= <25233464+colin-axner@users.noreply.github.com> Date: Mon, 15 Aug 2022 14:00:41 +0200 Subject: [PATCH 1/7] add scaffolding --- e2e/client_test.go | 71 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 71 insertions(+) create mode 100644 e2e/client_test.go diff --git a/e2e/client_test.go b/e2e/client_test.go new file mode 100644 index 00000000000..f9c86682ce7 --- /dev/null +++ b/e2e/client_test.go @@ -0,0 +1,71 @@ +package e2e + +/* +The ClientTestSuite assumes both chainA and chainB support the ClientUpdate Proposal. +*/ + +import ( + "context" + "fmt" + "testing" + + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/strangelove-ventures/ibctest" + "github.com/strangelove-ventures/ibctest/chain/cosmos" + "github.com/strangelove-ventures/ibctest/ibc" + "github.com/strangelove-ventures/ibctest/test" + "github.com/stretchr/testify/suite" + + "github.com/cosmos/ibc-go/e2e/testsuite" + "github.com/cosmos/ibc-go/e2e/testvalues" + transfertypes "github.com/cosmos/ibc-go/v5/modules/apps/transfer/types" + clienttypes "github.com/cosmos/ibc-go/v5/modules/core/02-client/types" +) + +func TestClientTestSuite(t *testing.T) { + suite.Run(t, new(ClientTestSuite)) +} + +type ClientTestSuite struct { + testsuite.E2ETestSuite +} + +func (s *ClientTestSuite) TestClientUpdateProposal_Succeeds() { + t := s.T() + ctx := context.TODO() + + relayer, channelA := s.SetupChainsRelayerAndChannel(ctx, transferChannelOptions()) + chainA, chainB := s.GetChains() + + chainAWallet := s.CreateUserOnChainA(ctx, testvalues.StartingTokenAmount) + chainAAddress := chainAWallet.Bech32Address(chainA.Config().Bech32Prefix) + + t.Run("create subject client with bad trusting period", func(t *testing.T) { + + }) + + t.Run("ensure subject client is expired", func(t *testing.T) { + + }) + + t.Run("create substitute client with correct trusting period", func(t *testing.T) { + + }) + + t.Run("pass client update proposal", func(t *testing.T) { + t.Run("create and submit proposal", func(t *testing.T) { + + }) + + t.Run("vote on proposal", func(t *testing.T) { + + }) + t.Run("wait for proposal to pass", func(t *testing.T) { + + }) + }) + + t.Run("ensure subject client has been updated", func(t *testing.T) { + + }) +} From 0aca07ecee76b9475f73e717ec9cacdd207f4a1f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Colin=20Axn=C3=A9r?= <25233464+colin-axner@users.noreply.github.com> Date: Mon, 22 Aug 2022 13:04:45 +0200 Subject: [PATCH 2/7] continue scaffolding --- e2e/client_test.go | 39 +++++++++++++++++++++++++++++++-------- 1 file changed, 31 insertions(+), 8 deletions(-) diff --git a/e2e/client_test.go b/e2e/client_test.go index f9c86682ce7..4fd647ea9fe 100644 --- a/e2e/client_test.go +++ b/e2e/client_test.go @@ -20,6 +20,7 @@ import ( "github.com/cosmos/ibc-go/e2e/testvalues" transfertypes "github.com/cosmos/ibc-go/v5/modules/apps/transfer/types" clienttypes "github.com/cosmos/ibc-go/v5/modules/core/02-client/types" + ibcexported "github.com/cosmos/ibc-go/v5/modules/core/exported" ) func TestClientTestSuite(t *testing.T) { @@ -30,36 +31,58 @@ type ClientTestSuite struct { testsuite.E2ETestSuite } +// CreateClient broadcasts a MsgCreateClient message. +func (s *TransferTestSuite) CreateClient(ctx context.Context, chain *cosmos.CosmosChain, user *ibctest.User, + clientState ibcexported.ClientState, counterpartyChain *cosmos.CosmosChain, +) (sdk.TxResponse, error) { + msg, err := clienttypes.NewMsgCreateClient(clientState, consensusState, user.Bech32Address(chain.Config().Bech32Prefix)) + s.Require().NoError(err) + return s.BroadcastMessages(ctx, chain, user, msg) +} + func (s *ClientTestSuite) TestClientUpdateProposal_Succeeds() { t := s.T() ctx := context.TODO() - relayer, channelA := s.SetupChainsRelayerAndChannel(ctx, transferChannelOptions()) - chainA, chainB := s.GetChains() + t.Run("create substitute client with correct trusting period", func(t *testing.T) { + relayer, channelA := s.SetupClients(ctx) + chainA, chainB := s.GetChains() + + }) chainAWallet := s.CreateUserOnChainA(ctx, testvalues.StartingTokenAmount) chainAAddress := chainAWallet.Bech32Address(chainA.Config().Bech32Prefix) t.Run("create subject client with bad trusting period", func(t *testing.T) { + clientState = ibctm.NewClientState( + chainB.ChainID, tmConfig.TrustLevel, tmConfig.TrustingPeriod, tmConfig.UnbondingPeriod, tmConfig.MaxClockDrift, + height, commitmenttypes.GetSDKSpecs(), UpgradePath) + createClientTxResp, err := s.CreateClient(ctx, chainA, chainAWallet) + s.Require().NoError(err) + s.AssertValidTxResponse(createClientTxResp) }) t.Run("ensure subject client is expired", func(t *testing.T) { - - }) - - t.Run("create substitute client with correct trusting period", func(t *testing.T) { - + status := s.Status() + s.Require().Equal(ibcexported.Expired, status) }) t.Run("pass client update proposal", func(t *testing.T) { t.Run("create and submit proposal", func(t *testing.T) { + prop, err := s.ClientUpdateProposal() + s.Require().NoError(err) + s.Require().NotNil(prop) + err := s.SubmitProposal(prop) + s.Require().NoError(err) }) t.Run("vote on proposal", func(t *testing.T) { - + err := s.VoteYes(prop) + s.Require().NoError(err) }) + t.Run("wait for proposal to pass", func(t *testing.T) { }) From 35a8a786e6f76922f14f6877caf2a7bd10de05d6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Colin=20Axn=C3=A9r?= <25233464+colin-axner@users.noreply.github.com> Date: Thu, 25 Aug 2022 19:15:00 +0200 Subject: [PATCH 3/7] add client recovery proposal test --- e2e/client_test.go | 98 ++++++++++++++++++++++---------------- e2e/go.mod | 6 +-- e2e/go.sum | 4 +- e2e/testsuite/testsuite.go | 15 +++++- 4 files changed, 75 insertions(+), 48 deletions(-) diff --git a/e2e/client_test.go b/e2e/client_test.go index 4fd647ea9fe..b518e0c5522 100644 --- a/e2e/client_test.go +++ b/e2e/client_test.go @@ -1,26 +1,19 @@ package e2e -/* -The ClientTestSuite assumes both chainA and chainB support the ClientUpdate Proposal. -*/ - import ( "context" - "fmt" "testing" + "time" - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/strangelove-ventures/ibctest" - "github.com/strangelove-ventures/ibctest/chain/cosmos" "github.com/strangelove-ventures/ibctest/ibc" "github.com/strangelove-ventures/ibctest/test" "github.com/stretchr/testify/suite" "github.com/cosmos/ibc-go/e2e/testsuite" "github.com/cosmos/ibc-go/e2e/testvalues" - transfertypes "github.com/cosmos/ibc-go/v5/modules/apps/transfer/types" clienttypes "github.com/cosmos/ibc-go/v5/modules/core/02-client/types" ibcexported "github.com/cosmos/ibc-go/v5/modules/core/exported" + ibctesting "github.com/cosmos/ibc-go/v5/testing" ) func TestClientTestSuite(t *testing.T) { @@ -31,64 +24,87 @@ type ClientTestSuite struct { testsuite.E2ETestSuite } -// CreateClient broadcasts a MsgCreateClient message. -func (s *TransferTestSuite) CreateClient(ctx context.Context, chain *cosmos.CosmosChain, user *ibctest.User, - clientState ibcexported.ClientState, counterpartyChain *cosmos.CosmosChain, -) (sdk.TxResponse, error) { - msg, err := clienttypes.NewMsgCreateClient(clientState, consensusState, user.Bech32Address(chain.Config().Bech32Prefix)) - s.Require().NoError(err) - return s.BroadcastMessages(ctx, chain, user, msg) +// Status queries the current status of the client +func (s *ClientTestSuite) Status(ctx context.Context, chain ibc.Chain, clientID string) (string, error) { + queryClient := s.GetChainGRCPClients(chain).ClientQueryClient + res, err := queryClient.ClientStatus(ctx, &clienttypes.QueryClientStatusRequest{ + ClientId: clientID, + }) + if err != nil { + return "", err + } + + return res.Status, nil } func (s *ClientTestSuite) TestClientUpdateProposal_Succeeds() { t := s.T() ctx := context.TODO() + var ( + relayer ibc.Relayer + subjectClientID string + substituteClientID string + badTrustingPeriod = time.Duration(time.Second) + ) + t.Run("create substitute client with correct trusting period", func(t *testing.T) { - relayer, channelA := s.SetupClients(ctx) - chainA, chainB := s.GetChains() + relayer, _ = s.SetupChainsRelayerAndChannel(ctx, transferChannelOptions()) + // TODO: update when client identifier created is accessible + // currently assumes first client is 07-tendermint-0 + substituteClientID = clienttypes.FormatClientIdentifier(ibcexported.Tendermint, 0) }) + chainA, chainB := s.GetChains() chainAWallet := s.CreateUserOnChainA(ctx, testvalues.StartingTokenAmount) - chainAAddress := chainAWallet.Bech32Address(chainA.Config().Bech32Prefix) t.Run("create subject client with bad trusting period", func(t *testing.T) { - clientState = ibctm.NewClientState( - chainB.ChainID, tmConfig.TrustLevel, tmConfig.TrustingPeriod, tmConfig.UnbondingPeriod, tmConfig.MaxClockDrift, - height, commitmenttypes.GetSDKSpecs(), UpgradePath) + createClientOptions := ibc.CreateClientOptions{ + TrustingPeriod: badTrustingPeriod.String(), + } - createClientTxResp, err := s.CreateClient(ctx, chainA, chainAWallet) - s.Require().NoError(err) - s.AssertValidTxResponse(createClientTxResp) - }) + s.SetupClients(ctx, relayer, createClientOptions) - t.Run("ensure subject client is expired", func(t *testing.T) { - status := s.Status() - s.Require().Equal(ibcexported.Expired, status) + // TODO: update when client identifier created is accessible + // currently assumes second client is 07-tendermint-1 + subjectClientID = clienttypes.FormatClientIdentifier(ibcexported.Tendermint, 1) }) - t.Run("pass client update proposal", func(t *testing.T) { - t.Run("create and submit proposal", func(t *testing.T) { - prop, err := s.ClientUpdateProposal() - s.Require().NoError(err) - s.Require().NotNil(prop) + time.Sleep(badTrustingPeriod) + + s.Require().NoError(test.WaitForBlocks(ctx, 1, chainA, chainB), "failed to wait for blocks") - err := s.SubmitProposal(prop) + t.Run("check status of each client", func(t *testing.T) { + t.Run("substitute should be active", func(t *testing.T) { + status, err := s.Status(ctx, chainA, substituteClientID) s.Require().NoError(err) + s.Require().Equal(ibcexported.Active.String(), status) }) - t.Run("vote on proposal", func(t *testing.T) { - err := s.VoteYes(prop) + t.Run("subject should be expired", func(t *testing.T) { + status, err := s.Status(ctx, chainA, subjectClientID) s.Require().NoError(err) + s.Require().Equal(ibcexported.Expired.String(), status) }) + }) - t.Run("wait for proposal to pass", func(t *testing.T) { - - }) + 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) }) - t.Run("ensure subject client has been updated", func(t *testing.T) { + t.Run("check status of each client", func(t *testing.T) { + t.Run("substitute should be active", func(t *testing.T) { + status, err := s.Status(ctx, chainA, substituteClientID) + s.Require().NoError(err) + s.Require().Equal(ibcexported.Active.String(), status) + }) + t.Run("subject should be active", func(t *testing.T) { + status, err := s.Status(ctx, chainA, subjectClientID) + s.Require().NoError(err) + s.Require().Equal(ibcexported.Active.String(), status) + }) }) } diff --git a/e2e/go.mod b/e2e/go.mod index f9d41d1df98..902a1758bef 100644 --- a/e2e/go.mod +++ b/e2e/go.mod @@ -9,9 +9,11 @@ require ( github.com/cosmos/ibc-go/v5 v5.0.0-beta1 github.com/cosmos/interchain-accounts v0.3.1-0.20220816085955-393d8444c111 github.com/docker/docker v20.10.17+incompatible - github.com/strangelove-ventures/ibctest v0.0.0-20220824150312-9d02bdb119b0 + github.com/strangelove-ventures/ibctest v0.0.0-20220824180329-f73a9f936fce github.com/stretchr/testify v1.8.0 + github.com/tendermint/tendermint v0.34.20 go.uber.org/zap v1.21.0 + golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4 google.golang.org/grpc v1.48.0 ) @@ -159,7 +161,6 @@ require ( github.com/tendermint/btcd v0.1.1 // indirect github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15 // indirect github.com/tendermint/go-amino v0.16.0 // indirect - github.com/tendermint/tendermint v0.34.20 // indirect github.com/tendermint/tm-db v0.6.7 // indirect github.com/ulikunitz/xz v0.5.8 // indirect github.com/vedhavyas/go-subkey v1.0.3 // indirect @@ -169,7 +170,6 @@ require ( go.uber.org/atomic v1.9.0 // indirect go.uber.org/multierr v1.8.0 // indirect golang.org/x/crypto v0.0.0-20220525230936-793ad666bf5e // indirect - golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4 // indirect golang.org/x/net v0.0.0-20220617184016-355a448f1bc9 // indirect golang.org/x/oauth2 v0.0.0-20220411215720-9780585627b5 // indirect golang.org/x/sync v0.0.0-20220513210516-0976fa681c29 // indirect diff --git a/e2e/go.sum b/e2e/go.sum index ac756c93bc9..5e55727ba7f 100644 --- a/e2e/go.sum +++ b/e2e/go.sum @@ -1255,8 +1255,8 @@ github.com/status-im/keycard-go v0.0.0-20190316090335-8537d3370df4/go.mod h1:RZL github.com/stbenjam/no-sprintf-host-port v0.1.1/go.mod h1:TLhvtIvONRzdmkFiio4O8LHsN9N74I+PhRquPsxpL0I= github.com/strangelove-ventures/go-subkey v1.0.7 h1:cOP/Lajg3uxV/tvspu0m6+0Cu+DJgygkEAbx/s+f35I= github.com/strangelove-ventures/go-subkey v1.0.7/go.mod h1:E34izOIEm+sZ1YmYawYRquqBQWeZBjVB4pF7bMuhc1c= -github.com/strangelove-ventures/ibctest v0.0.0-20220824150312-9d02bdb119b0 h1:IBb9ktwUfrLcBLCAZz2Yf9qMz98U/1Nc1HpQFhA92qQ= -github.com/strangelove-ventures/ibctest v0.0.0-20220824150312-9d02bdb119b0/go.mod h1:fwqMUdv+pE55HipI/b+7+8xbjrqePGYTEHoZOtWvTqQ= +github.com/strangelove-ventures/ibctest v0.0.0-20220824180329-f73a9f936fce h1:CwbsETcaS9sRbcRdiwfxlZTn3hrpEYW2vAvMTPJDa4M= +github.com/strangelove-ventures/ibctest v0.0.0-20220824180329-f73a9f936fce/go.mod h1:fwqMUdv+pE55HipI/b+7+8xbjrqePGYTEHoZOtWvTqQ= github.com/streadway/amqp v0.0.0-20190404075320-75d898a42a94/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= github.com/streadway/amqp v1.0.0/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= github.com/streadway/handy v0.0.0-20200128134331-0f66f006fb2e/go.mod h1:qNTQ5P5JnDBl6z3cMAg/SywNDC5ABu5ApDIw6lUbRmI= diff --git a/e2e/testsuite/testsuite.go b/e2e/testsuite/testsuite.go index e74055697c3..548bd3ac27a 100644 --- a/e2e/testsuite/testsuite.go +++ b/e2e/testsuite/testsuite.go @@ -108,8 +108,7 @@ func (s *E2ETestSuite) SetupChainsRelayerAndChannel(ctx context.Context, channel r := newCosmosRelayer(s.T(), testconfig.FromEnv(), s.logger, s.DockerClient, s.network) - pathName := fmt.Sprintf("%s-path", s.T().Name()) - pathName = strings.ReplaceAll(pathName, "/", "-") + pathName := s.getPathName() ic := ibctest.NewInterchain(). AddChain(chainA). @@ -157,6 +156,18 @@ func (s *E2ETestSuite) SetupChainsRelayerAndChannel(ctx context.Context, channel return r, chainAChannels[len(chainAChannels)-1] } +// getPathName generates the path name using the test suites name +func (s *E2ETestSuite) getPathName() string { + pathName := fmt.Sprintf("%s-path", s.T().Name()) + return strings.ReplaceAll(pathName, "/", "-") +} + +// SetupClients creates clients on chainA and chainB using the provided create client options +func (s *E2ETestSuite) SetupClients(ctx context.Context, relayer ibc.Relayer, opts ibc.CreateClientOptions) { + err := relayer.CreateClients(ctx, s.GetRelayerExecReporter(), s.getPathName(), opts) + s.Require().NoError(err) +} + // GetChains returns two chains that can be used in a test. The pair returned // is unique to the current test being run. Note: this function does not create containers. func (s *E2ETestSuite) GetChains(chainOpts ...testconfig.ChainOptionConfiguration) (*cosmos.CosmosChain, *cosmos.CosmosChain) { From 70fcd8a1a4d18212bafbc344cae7e57e9ce7a40d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Colin=20Axn=C3=A9r?= <25233464+colin-axner@users.noreply.github.com> Date: Mon, 29 Aug 2022 14:17:56 +0200 Subject: [PATCH 4/7] generate a new path when creating clients --- e2e/client_test.go | 11 +++++++++++ e2e/testsuite/testsuite.go | 34 +++++++++++++++++++++++++++++----- 2 files changed, 40 insertions(+), 5 deletions(-) diff --git a/e2e/client_test.go b/e2e/client_test.go index b518e0c5522..2cd6c982f6d 100644 --- a/e2e/client_test.go +++ b/e2e/client_test.go @@ -2,6 +2,8 @@ package e2e import ( "context" + "fmt" + "strings" "testing" "time" @@ -42,6 +44,7 @@ func (s *ClientTestSuite) TestClientUpdateProposal_Succeeds() { ctx := context.TODO() var ( + pathName string relayer ibc.Relayer subjectClientID string substituteClientID string @@ -54,6 +57,10 @@ func (s *ClientTestSuite) TestClientUpdateProposal_Succeeds() { // TODO: update when client identifier created is accessible // currently assumes first client is 07-tendermint-0 substituteClientID = clienttypes.FormatClientIdentifier(ibcexported.Tendermint, 0) + + // TODO: replace with better handling of path names + pathName = fmt.Sprintf("%s-path-%d", s.T().Name(), 0) + pathName = strings.ReplaceAll(pathName, "/", "-") }) chainA, chainB := s.GetChains() @@ -73,6 +80,10 @@ func (s *ClientTestSuite) TestClientUpdateProposal_Succeeds() { time.Sleep(badTrustingPeriod) + t.Run("update substitute client", func(t *testing.T) { + s.UpdateClients(ctx, relayer, pathName) + }) + s.Require().NoError(test.WaitForBlocks(ctx, 1, chainA, chainB), "failed to wait for blocks") t.Run("check status of each client", func(t *testing.T) { diff --git a/e2e/testsuite/testsuite.go b/e2e/testsuite/testsuite.go index 548bd3ac27a..4328e2efef7 100644 --- a/e2e/testsuite/testsuite.go +++ b/e2e/testsuite/testsuite.go @@ -49,6 +49,9 @@ type E2ETestSuite struct { DockerClient *dockerclient.Client network string startRelayerFn func(relayer ibc.Relayer) + + // pathNameIndex is the latest index to be used for generating paths + pathNameIndex uint64 } // GRPCClients holds a reference to any GRPC clients that are needed by the tests. @@ -108,7 +111,7 @@ func (s *E2ETestSuite) SetupChainsRelayerAndChannel(ctx context.Context, channel r := newCosmosRelayer(s.T(), testconfig.FromEnv(), s.logger, s.DockerClient, s.network) - pathName := s.getPathName() + pathName := s.generatePathName() ic := ibctest.NewInterchain(). AddChain(chainA). @@ -156,15 +159,36 @@ func (s *E2ETestSuite) SetupChainsRelayerAndChannel(ctx context.Context, channel return r, chainAChannels[len(chainAChannels)-1] } -// getPathName generates the path name using the test suites name -func (s *E2ETestSuite) getPathName() string { - pathName := fmt.Sprintf("%s-path", s.T().Name()) +// generatePathName generates the path name using the test suites name +func (s *E2ETestSuite) generatePathName() string { + pathName := fmt.Sprintf("%s-path-%d", s.T().Name(), s.pathNameIndex) + s.pathNameIndex++ return strings.ReplaceAll(pathName, "/", "-") } +// generatePath generates the path name using the test suites name +func (s *E2ETestSuite) generatePath(ctx context.Context, relayer ibc.Relayer) string { + chainA, chainB := s.GetChains() + chainAID := chainA.Config().ChainID + chainBID := chainB.Config().ChainID + + pathName := s.generatePathName() + err := relayer.GeneratePath(ctx, s.GetRelayerExecReporter(), chainAID, chainBID, pathName) + s.Require().NoError(err) + + return pathName +} + // SetupClients creates clients on chainA and chainB using the provided create client options func (s *E2ETestSuite) SetupClients(ctx context.Context, relayer ibc.Relayer, opts ibc.CreateClientOptions) { - err := relayer.CreateClients(ctx, s.GetRelayerExecReporter(), s.getPathName(), opts) + pathName := s.generatePath(ctx, relayer) + err := relayer.CreateClients(ctx, s.GetRelayerExecReporter(), pathName, opts) + s.Require().NoError(err) +} + +// UpdateClients updates clients on chainA and chainB using the provided create client options +func (s *E2ETestSuite) UpdateClients(ctx context.Context, relayer ibc.Relayer, pathName string) { + err := relayer.UpdateClients(ctx, s.GetRelayerExecReporter(), pathName) s.Require().NoError(err) } From 000b56d171406c6b58d3de3875048a92e24d95b5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Colin=20Axn=C3=A9r?= <25233464+colin-axner@users.noreply.github.com> Date: Mon, 29 Aug 2022 14:26:17 +0200 Subject: [PATCH 5/7] apply e2e restructure --- e2e/{ => tests/core}/client_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) rename e2e/{ => tests/core}/client_test.go (97%) diff --git a/e2e/client_test.go b/e2e/tests/core/client_test.go similarity index 97% rename from e2e/client_test.go rename to e2e/tests/core/client_test.go index 2cd6c982f6d..225a7c1fb27 100644 --- a/e2e/client_test.go +++ b/e2e/tests/core/client_test.go @@ -52,7 +52,7 @@ func (s *ClientTestSuite) TestClientUpdateProposal_Succeeds() { ) t.Run("create substitute client with correct trusting period", func(t *testing.T) { - relayer, _ = s.SetupChainsRelayerAndChannel(ctx, transferChannelOptions()) + relayer, _ = s.SetupChainsRelayerAndChannel(ctx) // TODO: update when client identifier created is accessible // currently assumes first client is 07-tendermint-0 From 69fa6642fb544abdc9301d7c3f8e5a6e4b23dd07 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?colin=20axn=C3=A9r?= <25233464+colin-axner@users.noreply.github.com> Date: Mon, 29 Aug 2022 14:31:38 +0200 Subject: [PATCH 6/7] Update e2e/testsuite/testsuite.go --- e2e/testsuite/testsuite.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/e2e/testsuite/testsuite.go b/e2e/testsuite/testsuite.go index 296e7a66bac..759d414ba1d 100644 --- a/e2e/testsuite/testsuite.go +++ b/e2e/testsuite/testsuite.go @@ -188,7 +188,7 @@ func (s *E2ETestSuite) SetupClients(ctx context.Context, relayer ibc.Relayer, op s.Require().NoError(err) } -// UpdateClients updates clients on chainA and chainB using the provided create client options +// UpdateClients updates clients on chainA and chainB func (s *E2ETestSuite) UpdateClients(ctx context.Context, relayer ibc.Relayer, pathName string) { err := relayer.UpdateClients(ctx, s.GetRelayerExecReporter(), pathName) s.Require().NoError(err) From d8b426da003bc08535fe04dcfc149bcd63dfa5d1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Colin=20Axn=C3=A9r?= <25233464+colin-axner@users.noreply.github.com> Date: Mon, 29 Aug 2022 18:01:19 +0200 Subject: [PATCH 7/7] bump relayer version to v2.0.0 --- .github/workflows/e2e-fork.yml | 2 +- .github/workflows/e2e-manual-icad.yaml | 2 +- .github/workflows/e2e-manual-simd.yaml | 2 +- .github/workflows/e2e-test-workflow-call.yml | 2 +- .github/workflows/e2e.yaml | 2 +- e2e/README.md | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/e2e-fork.yml b/.github/workflows/e2e-fork.yml index 69dbb819eb5..d3a576b41ab 100644 --- a/.github/workflows/e2e-fork.yml +++ b/.github/workflows/e2e-fork.yml @@ -48,7 +48,7 @@ jobs: - name: Run e2e Test env: # see images here https://github.com/cosmos/relayer/pkgs/container/relayer/versions - RLY_TAG: "v2.0.0-rc2" + RLY_TAG: "v2.0.0" run: | cd e2e make e2e-test entrypoint=${{ matrix.entrypoint }} test=${{ matrix.test }} diff --git a/.github/workflows/e2e-manual-icad.yaml b/.github/workflows/e2e-manual-icad.yaml index 17518b550ec..0face187316 100644 --- a/.github/workflows/e2e-manual-icad.yaml +++ b/.github/workflows/e2e-manual-icad.yaml @@ -40,7 +40,7 @@ on: relayer-tag: description: 'The tag to use for the relayer' required: true - default: "v2.0.0-rc2" + default: "v2.0.0" type: string diff --git a/.github/workflows/e2e-manual-simd.yaml b/.github/workflows/e2e-manual-simd.yaml index 6ff0fc358d1..f9e1288ba30 100644 --- a/.github/workflows/e2e-manual-simd.yaml +++ b/.github/workflows/e2e-manual-simd.yaml @@ -44,7 +44,7 @@ on: relayer-tag: description: 'The tag to use for the relayer' required: true - default: "v2.0.0-rc2" + default: "v2.0.0" type: string diff --git a/.github/workflows/e2e-test-workflow-call.yml b/.github/workflows/e2e-test-workflow-call.yml index 428ee8b85d7..8c57660befc 100644 --- a/.github/workflows/e2e-test-workflow-call.yml +++ b/.github/workflows/e2e-test-workflow-call.yml @@ -34,7 +34,7 @@ on: relayer-tag: description: 'The tag to use for the relayer' required: true - default: "v2.0.0-rc2" + default: "v2.0.0" type: string build-and-push-docker-image: description: "Flag to specify if the docker image should be built and pushed beforehand" diff --git a/.github/workflows/e2e.yaml b/.github/workflows/e2e.yaml index 9afd81fba29..1cd49def227 100644 --- a/.github/workflows/e2e.yaml +++ b/.github/workflows/e2e.yaml @@ -41,7 +41,7 @@ jobs: chain-image: ghcr.io/cosmos/ibc-go-simd chain-a-tag: "${{ needs.determine-image-tag.outputs.simd-tag }}" chain-b-tag: "${{ needs.determine-image-tag.outputs.simd-tag }}" - relayer-tag: "v2.0.0-rc2" + relayer-tag: "v2.0.0" chain-binary: "simd" # on regular PRs we won't run interchain account tests. test-exclusions: "TestInterchainAccountsTestSuite,TestIncentivizedInterchainAccountsTestSuite" diff --git a/e2e/README.md b/e2e/README.md index 363f713126d..5f8c842ff15 100644 --- a/e2e/README.md +++ b/e2e/README.md @@ -68,7 +68,7 @@ export CHAIN_BINARY="simd" # export CHAIN_B_TAG="main" # export CHAIN_BINARY="icad" -export RLY_TAG="v2.0.0-rc2" +export RLY_TAG="v2.0.0" make e2e-test entrypoint=TestInterchainAccountsTestSuite test=TestMsgSubmitTx_SuccessfulTransfer ```