1 | <?php |
||
22 | class DeleteActionTest extends TestCase |
||
23 | { |
||
24 | use ConfigTrait; |
||
25 | use FixturesTrait; |
||
26 | |||
27 | /** |
||
28 | * @var DeleteAction |
||
29 | */ |
||
30 | public $Action; |
||
31 | |||
32 | /** |
||
33 | * setUp method |
||
34 | * |
||
35 | * @return void |
||
36 | */ |
||
37 | public function setUp() |
||
41 | |||
42 | /** |
||
43 | * tearDown method |
||
44 | * |
||
45 | * @return void |
||
46 | */ |
||
47 | public function tearDown() |
||
53 | |||
54 | /** |
||
55 | * @return void |
||
56 | */ |
||
57 | public function testExecuteSuccess() |
||
70 | |||
71 | /** |
||
72 | * @return void |
||
73 | * @expectedException \CakeDC\Api\Exception\ValidationException |
||
74 | */ |
||
75 | public function testValidationPostNotArray() |
||
82 | |||
83 | /** |
||
84 | * @return void |
||
85 | * @expectedException \CakeDC\Api\Exception\ValidationException |
||
86 | */ |
||
87 | public function testValidationPostEmpty() |
||
92 | |||
93 | /** |
||
94 | * @return void |
||
95 | * @expectedException \CakeDC\Api\Exception\ValidationException |
||
96 | */ |
||
97 | public function testValidationPostString() |
||
102 | |||
103 | /** |
||
104 | * @return void |
||
105 | * @expectedException \CakeDC\Api\Exception\ValidationException |
||
106 | * @expectedExceptionMessage Validation failed |
||
107 | */ |
||
108 | public function testExecuteValidationEntityNotValid() |
||
117 | |||
118 | /** |
||
119 | * @return void |
||
120 | */ |
||
121 | public function testValidatesEntity() |
||
130 | |||
131 | /** |
||
132 | * @return void |
||
133 | */ |
||
134 | public function testValidatesEntityNotValid() |
||
155 | |||
156 | protected function _initializeAction($post = []) |
||
178 | } |
||
179 |
It seems like the type of the argument is not accepted by the function/method which you are calling.
In some cases, in particular if PHP’s automatic type-juggling kicks in this might be fine. In other cases, however this might be a bug.
We suggest to add an explicit type cast like in the following example: