Skip to content

Commit

Permalink
Rename path variable and un-alias path import.
Browse files Browse the repository at this point in the history
  • Loading branch information
bznein committed Apr 10, 2024
1 parent eba5cbc commit 35e3f74
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions e2e/testsuite/testsuite.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"errors"
"fmt"
"os"
gopath "path"
"path"
"strings"

dockerclient "github.com/docker/docker/client"
Expand Down Expand Up @@ -93,10 +93,10 @@ func (s *E2ETestSuite) ConfigureGenesisDebugExport() {
exportPath = gopath.Join(e2eDir, directories.DefaultGenesisExportPath)
}

if !gopath.IsAbs(exportPath) {
if !path.IsAbs(exportPath) {
wd, err := os.Getwd()
s.Require().NoError(err, "can't get working directory")
exportPath = gopath.Join(wd, exportPath)
exportPath = path.Join(wd, exportPath)
}

// This env variables are set by the interchain test code:
Expand Down Expand Up @@ -219,9 +219,9 @@ func (s *E2ETestSuite) SetupSingleChain(ctx context.Context) ibc.Chain {

// generatePathName generates the path name using the test suites name
func (s *E2ETestSuite) generatePathName() string {
path := s.GetPathName(s.pathNameIndex)
pathName := s.GetPathName(s.pathNameIndex)
s.pathNameIndex++
return path
return pathName
}

// GetPathName returns the name of a path at a specific index. This can be used in tests
Expand Down Expand Up @@ -265,9 +265,9 @@ func (s *E2ETestSuite) GetChains(chainOpts ...ChainOptionConfiguration) (ibc.Cha
s.paths = map[string]pathPair{}
}

path, ok := s.paths[s.T().Name()]
suitePath, ok := s.paths[s.T().Name()]
if ok {
return path.chainA, path.chainB
return suitePath.chainA, suitePath.chainB
}

chainOptions := DefaultChainOptions()
Expand All @@ -276,8 +276,8 @@ func (s *E2ETestSuite) GetChains(chainOpts ...ChainOptionConfiguration) (ibc.Cha
}

chainA, chainB := s.createChains(chainOptions)
path = newPath(chainA, chainB)
s.paths[s.T().Name()] = path
suitePath = newPath(chainA, chainB)
s.paths[s.T().Name()] = suitePath

if s.proposalIDs == nil {
s.proposalIDs = map[string]uint64{}
Expand All @@ -286,7 +286,7 @@ func (s *E2ETestSuite) GetChains(chainOpts ...ChainOptionConfiguration) (ibc.Cha
s.proposalIDs[chainA.Config().ChainID] = 1
s.proposalIDs[chainB.Config().ChainID] = 1

return path.chainA, path.chainB
return suitePath.chainA, suitePath.chainB
}

// GetRelayerWallets returns the ibcrelayer wallets associated with the chains.
Expand Down

0 comments on commit 35e3f74

Please sign in to comment.