Skip to content

Commit

Permalink
Merge PR cosmos#6626: Remove viper from genutil tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jgimeno authored Jul 7, 2020
1 parent 86243f6 commit c41b787
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions x/genutil/client/cli/init_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,11 @@ import (
"github.com/spf13/viper"
"github.com/stretchr/testify/require"
abci_server "github.com/tendermint/tendermint/abci/server"
tcmd "github.com/tendermint/tendermint/cmd/tendermint/commands"
tmcfg "github.com/tendermint/tendermint/config"
"github.com/tendermint/tendermint/libs/cli"
"github.com/tendermint/tendermint/libs/log"

"github.com/cosmos/cosmos-sdk/client"
"github.com/cosmos/cosmos-sdk/client/flags"
"github.com/cosmos/cosmos-sdk/codec"
cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec"
"github.com/cosmos/cosmos-sdk/server"
Expand Down Expand Up @@ -162,11 +160,8 @@ func TestStartStandAlone(t *testing.T) {

func TestInitNodeValidatorFiles(t *testing.T) {
home, cleanup := tests.NewTestCaseDir(t)
cfg, err := createDefaultTendermintConfig(home)
t.Cleanup(cleanup)
viper.Set(cli.HomeFlag, home)
viper.Set(flags.FlagName, "moniker")
cfg, err := tcmd.ParseConfig()
require.Nil(t, err)
nodeID, valPubKey, err := genutil.InitializeNodeValidatorFiles(cfg)
require.Nil(t, err)
require.NotEqual(t, "", nodeID)
Expand Down

0 comments on commit c41b787

Please sign in to comment.