Make error handling more obvious
Again, the code looks a little more like a middle-schooler's code. But that just makes it easier to understand and maintain.
This commit is contained in:
@ -768,7 +768,7 @@ func TestRootNoCommandHelp(t *testing.T) {
|
||||
|
||||
func TestRootUnknownCommand(t *testing.T) {
|
||||
r := noRRSetupTest("bogus")
|
||||
s := "Error: unknown command \"bogus\"\nRun 'cobra-test help' for usage.\n"
|
||||
s := "Error: unknown command \"bogus\"\nRun 'cobra-test --help' for usage.\n"
|
||||
|
||||
if r.Output != s {
|
||||
t.Errorf("Unexpected response.\nExpecting to be:\n %q\nGot:\n %q\n", s, r.Output)
|
||||
|
Reference in New Issue
Block a user