test: cleanup for go vet

Looks like copy'pasta and an unused variable

Signed-off-by: Vincent Batts <vbatts@hashbangbash.com>
This commit is contained in:
Vincent Batts 2016-09-08 09:49:50 -04:00
parent d99d0713f1
commit d8271a7c29
No known key found for this signature in database
GPG key ID: 10937E57733F1362

View file

@ -916,15 +916,14 @@ func TestRootUnknownCommand(t *testing.T) {
func TestRootUnknownCommandSilenced(t *testing.T) { func TestRootUnknownCommandSilenced(t *testing.T) {
r := noRRSetupTestSilenced("bogus") r := noRRSetupTestSilenced("bogus")
s := "Run 'cobra-test --help' for usage.\n"
if r.Output != "" { if r.Output != "" {
t.Errorf("Unexpected response.\nExpecting to be: \n\"\"\n Got:\n %q\n", s, r.Output) t.Errorf("Unexpected response.\nExpecting to be: \n\"\"\n Got:\n %q\n", r.Output)
} }
r = noRRSetupTestSilenced("--strtwo=a bogus") r = noRRSetupTestSilenced("--strtwo=a bogus")
if r.Output != "" { if r.Output != "" {
t.Errorf("Unexpected response.\nExpecting to be:\n\"\"\nGot:\n %q\n", s, r.Output) t.Errorf("Unexpected response.\nExpecting to be:\n\"\"\nGot:\n %q\n", r.Output)
} }
} }