50 lines
1.7 KiB
YAML
50 lines
1.7 KiB
YAML
name: ApplicationTester
|
|
class_comment: '# * Eases the testing of console applications.
|
|
|
|
# *
|
|
|
|
# * When testing an application, don''t forget to disable the auto exit flag:
|
|
|
|
# *
|
|
|
|
# * $application = new Application();
|
|
|
|
# * $application->setAutoExit(false);
|
|
|
|
# *
|
|
|
|
# * @author Fabien Potencier <fabien@symfony.com>'
|
|
dependencies:
|
|
- name: Application
|
|
type: class
|
|
source: Symfony\Component\Console\Application
|
|
- name: ArrayInput
|
|
type: class
|
|
source: Symfony\Component\Console\Input\ArrayInput
|
|
- name: TesterTrait
|
|
type: class
|
|
source: TesterTrait
|
|
properties: []
|
|
methods:
|
|
- name: run
|
|
visibility: public
|
|
parameters:
|
|
- name: input
|
|
- name: options
|
|
default: '[]'
|
|
comment: "# * Eases the testing of console applications.\n# *\n# * When testing\
|
|
\ an application, don't forget to disable the auto exit flag:\n# *\n# * $application\
|
|
\ = new Application();\n# * $application->setAutoExit(false);\n# *\n# * @author\
|
|
\ Fabien Potencier <fabien@symfony.com>\n# */\n# class ApplicationTester\n# {\n\
|
|
# use TesterTrait;\n# \n# public function __construct(\n# private Application\
|
|
\ $application,\n# ) {\n# }\n# \n# /**\n# * Executes the application.\n# *\n#\
|
|
\ * Available options:\n# *\n# * * interactive: Sets the input\
|
|
\ interactive flag\n# * * decorated: Sets the output decorated\
|
|
\ flag\n# * * verbosity: Sets the output verbosity flag\n# *\
|
|
\ * capture_stderr_separately: Make output of stdOut and stdErr separately available\n\
|
|
# *\n# * @return int The command exit code"
|
|
traits:
|
|
- Symfony\Component\Console\Application
|
|
- Symfony\Component\Console\Input\ArrayInput
|
|
- TesterTrait
|
|
interfaces: []
|