class PendingCommand (View source)
TestCase | $test | The test being run. | |
protected Application | $app | The application instance. | |
protected string | $command | The command to run. | |
protected array | $parameters | The parameters to pass to the command. | |
protected int | $expectedExitCode | The expected exit code. | |
protected bool | $hasExecuted | Determine if command has executed. |
void | __construct(TestCase $test, Application $app, string $command, array $parameters) Create a new pending console command run. | |
$this | expectsQuestion(string $question, string $answer) Specify a question that should be asked when the command runs. | |
$this | expectsOutput(string $output) Specify output that should be printed when the command runs. | |
$this | assertExitCode(int $exitCode) Assert that the command has the given exit code. | |
int | execute() Execute the command. | |
int | run() Execute the command. | |
void | mockConsoleOutput() Mock the application's console output. | |
void | __destruct() Handle the object's destruction. |
Create a new pending console command run.
Specify a question that should be asked when the command runs.
Specify output that should be printed when the command runs.
Assert that the command has the given exit code.
Execute the command.
Execute the command.
Mock the application's console output.
Handle the object's destruction.
© Taylor Otwell
Licensed under the MIT License.
Laravel is a trademark of Taylor Otwell.
https://laravel.com/api/5.7/Illuminate/Foundation/Testing/PendingCommand.html