1 | <?php declare(strict_types=1); |
||
20 | class Context extends AbstractContext |
||
21 | { |
||
22 | use Response; |
||
23 | |||
24 | public function __construct(HttpHistory $history) |
||
29 | |||
30 | /** {@inheritDoc} */ |
||
31 | protected function getJson() |
||
35 | |||
36 | protected function getContentTypes(): array |
||
40 | |||
41 | /** |
||
42 | * @Then the response should be a valid json response |
||
43 | * |
||
44 | * --- |
||
45 | * |
||
46 | * This method is built-on the default php's json extension. You should |
||
47 | * overwrite it if you want to add supplementary checks or use something |
||
48 | * else instead (such as Seldaek's JsonLint package). |
||
49 | */ |
||
50 | public function responseIsValidjson() |
||
59 | } |
||
60 |
This check marks access to variables or properties that have not been declared yet. While PHP has no explicit notion of declaring a variable, accessing it before a value is assigned to it is most likely a bug.