Update for new context
This commit is contained in:
parent
74a2246b3e
commit
8c0cb25bab
|
@ -48,13 +48,16 @@ func TestStartWithTendermint(t *testing.T) {
|
|||
|
||||
logger := log.NewTMLogger(log.NewSyncWriter(os.Stdout)).
|
||||
With("module", "mock-cmd")
|
||||
initCmd := InitCmd(mock.GenInitOptions, logger)
|
||||
err := initCmd.RunE(nil, nil)
|
||||
cfg, err := tcmd.ParseConfig()
|
||||
require.Nil(t, err)
|
||||
ctx := NewContext(cfg, logger)
|
||||
initCmd := InitCmd(mock.GenInitOptions, ctx)
|
||||
err = initCmd.RunE(nil, nil)
|
||||
require.NoError(t, err)
|
||||
|
||||
// set up app and start up
|
||||
viper.Set(flagWithTendermint, true)
|
||||
startCmd := StartCmd(mock.NewApp, logger)
|
||||
startCmd := StartCmd(mock.NewApp, ctx)
|
||||
startCmd.Flags().Set(flagAddress, FreeTCPAddr(t)) // set to a new free address
|
||||
timeout := time.Duration(5) * time.Second
|
||||
|
||||
|
|
Loading…
Reference in New Issue