fixes verbose tests by checking if the first arg belongs to cobra

This commit is contained in:
Austin Riendeau 2015-11-07 11:42:13 -07:00
parent 0e4c02d9cb
commit 62e859a9ed

View file

@ -618,7 +618,7 @@ func (c *Command) Execute() (err error) {
var args []string
if len(c.args) == 0 {
if len(c.args) == 0 && os.Args[0] == c.Name() {
args = os.Args[1:]
} else {
args = c.args