1 | <?php |
||
22 | final class CommandContext implements Context |
||
23 | { |
||
24 | use KernelDictionary; |
||
25 | |||
26 | /** |
||
27 | * @var null |
||
28 | */ |
||
29 | private $application = null; |
||
30 | |||
31 | /** |
||
32 | * @var null|string |
||
33 | */ |
||
34 | private $command_output = null; |
||
35 | |||
36 | /** |
||
37 | * @var null|\Exception |
||
38 | */ |
||
39 | private $command_exception = null; |
||
40 | |||
41 | /** |
||
42 | * @var null|int |
||
43 | */ |
||
44 | private $command_exit_code = null; |
||
45 | |||
46 | /** |
||
47 | * @param array $command_parameters |
||
48 | */ |
||
49 | public function setCommandParameters($command_parameters) |
||
53 | |||
54 | /** |
||
55 | * @param int|null $command_exit_code |
||
56 | */ |
||
57 | public function setCommandExitCode($command_exit_code) |
||
61 | |||
62 | /** |
||
63 | * @param \Exception|null $command_exception |
||
64 | */ |
||
65 | public function setCommandException($command_exception) |
||
69 | |||
70 | /** |
||
71 | * @var array |
||
72 | */ |
||
73 | private $command_parameters = []; |
||
74 | |||
75 | /** |
||
76 | * @param string $command_output |
||
77 | */ |
||
78 | protected function setCommandOutput($command_output) |
||
82 | |||
83 | /** |
||
84 | * @return null|string |
||
85 | */ |
||
86 | protected function getCommandOutput() |
||
90 | |||
91 | /** |
||
92 | * @return null|array |
||
93 | */ |
||
94 | protected function getCommandParameters() |
||
98 | |||
99 | /** |
||
100 | * @return null|\Exception |
||
101 | */ |
||
102 | protected function getCommandException() |
||
106 | |||
107 | /** |
||
108 | * @return null|int |
||
109 | */ |
||
110 | protected function getCommandExitCode() |
||
114 | |||
115 | /** |
||
116 | * @return Application |
||
117 | */ |
||
118 | protected function getApplication() |
||
126 | |||
127 | /** |
||
128 | * @Given I wait :time seconds |
||
129 | */ |
||
130 | public function iWaitSeconds($time) |
||
134 | |||
135 | /** |
||
136 | * @When I run command :line |
||
137 | */ |
||
138 | public function iRunCommand($line) |
||
158 | |||
159 | /** |
||
160 | * @Given I run command :line with parameters |
||
161 | */ |
||
162 | public function iRunACommandWithParameters($line, PyStringNode $parameterJson) |
||
173 | |||
174 | /** |
||
175 | * @Then I should see |
||
176 | */ |
||
177 | public function iShouldSee(PyStringNode $result) |
||
184 | |||
185 | /** |
||
186 | * @Then I should see something like :pattern |
||
187 | */ |
||
188 | public function iShouldSeeSomethingLike($pattern) |
||
195 | |||
196 | /** |
||
197 | * @Then The command exception should not be thrown |
||
198 | */ |
||
199 | public function theCommandExceptionShouldNotBeThrown() |
||
205 | |||
206 | /** |
||
207 | * @Then The command exception :exception should be thrown |
||
208 | */ |
||
209 | public function theCommandExceptionShouldBeThrown($exception) |
||
215 | |||
216 | /** |
||
217 | * @Then The command exit code should be :code |
||
218 | */ |
||
219 | public function theCommandExitCodeShouldBe($code) |
||
225 | |||
226 | /** |
||
227 | * @Then The command exception :exception with message should be thrown |
||
228 | */ |
||
229 | public function theCommandExceptionWithMessageShouldBeThrown($exception, PyStringNode $message) |
||
236 | |||
237 | /** |
||
238 | * @Then The command exception :exception with message like :pattern should be thrown |
||
239 | */ |
||
240 | public function theCommandExceptionWithMessageLikeShouldBeThrown($exception, $pattern) |
||
247 | |||
248 | /** |
||
249 | * @param string $command |
||
250 | * |
||
251 | * @return array |
||
252 | */ |
||
253 | private function getCommandParams($command) |
||
260 | } |
||
261 |
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..