Skip to content

Cookbook/Console/ConsoleCommand : Adding option/argument example in test #2793

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jul 18, 2013

Conversation

gregquat
Copy link
Contributor

@gregquat gregquat commented Jul 3, 2013

See comments in the PR #2792 I made on 2.1 branch

@xabbuh
Copy link
Member

xabbuh commented Jul 3, 2013

Okay, I understand your reasons.

By the way, is the command argument really necessary? I don't see for what it's worth.

@gregquat
Copy link
Contributor Author

gregquat commented Jul 3, 2013

No, it's not necessary since the command works well without. But I think the example is complete this way since the command name, an argument, and an option are provided/shown.

Maybe I can add a comment or something to specify that they are not mandatory.

@xabbuh
Copy link
Member

xabbuh commented Jul 3, 2013

As far as I understand the command argument is completely useless. Thus, I think we should remove these lines.

@gregquat
Copy link
Contributor Author

gregquat commented Jul 3, 2013

The command argument was the only one that was already in the doc. And for that matters, if your command requires any argument to work, you must provide it (that was my problem, and the answer was not in the doc) to test it correctly.

@weaverryan , @wouterj what do you think about that please?

@stof
Copy link
Member

stof commented Jul 3, 2013

except that ``command` is not an argument required by the command but used by the application (to select the right command). As you are running the command directly, you don't need the command name in the input

weaverryan added a commit that referenced this pull request Jul 18, 2013
Cookbook/Console/ConsoleCommand : Adding option/argument example in test
@weaverryan weaverryan merged commit ecbeae8 into symfony:2.2 Jul 18, 2013
@weaverryan
Copy link
Member

Hi guys!

I really like this addition - @gregquat you're absolutely right that having more complete examples are great. I've also removed the command option per @stof's suggestion at sha: 16e5577

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants