testutil: add ApplyMockIODiscardOutErr, simplify existing functions (#6665)

This commit is contained in:
Alessio Treglia
2020-07-10 08:55:48 +02:00
committed by GitHub
parent d269eaf74c
commit 255ed06eb4
16 changed files with 63 additions and 36 deletions
+1 -2
View File
@@ -28,8 +28,7 @@ func TestMigrateGenesis(t *testing.T) {
target := "v0.36"
cmd := MigrateGenesisCmd()
cmd.SetErr(ioutil.Discard)
cmd.SetOut(ioutil.Discard)
_ = testutil.ApplyMockIODiscardOutErr(cmd)
clientCtx := client.Context{}.WithJSONMarshaler(cdc)
ctx := context.Background()