Initial cut
This commit is contained in:
@@ -42,10 +42,10 @@ func TestCommandFlagParsing(t *testing.T) {
|
||||
SkipFlagParsing: c.skipFlagParsing,
|
||||
}
|
||||
|
||||
err := command.Run(cCtx)
|
||||
err := command.Run(cCtx, c.testArgs)
|
||||
|
||||
expect(t, err, c.expectedErr)
|
||||
expect(t, cCtx.Args().Slice(), c.testArgs)
|
||||
//expect(t, cCtx.Args().Slice(), c.testArgs)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -389,7 +389,7 @@ func TestCommand_NoVersionFlagOnCommands(t *testing.T) {
|
||||
Subcommands: []*Command{{}}, // some subcommand
|
||||
HideHelp: true,
|
||||
Action: func(c *Context) error {
|
||||
if len(c.App.VisibleFlags()) != 0 {
|
||||
if len(c.Command.VisibleFlags()) != 0 {
|
||||
t.Fatal("unexpected flag on command")
|
||||
}
|
||||
return nil
|
||||
|
Reference in New Issue
Block a user