@@ 186-195 (lines=10) @@ | ||
183 | * @group cget |
|
184 | * @group controller |
|
185 | */ |
|
186 | public function testCGetInvalide() |
|
187 | { |
|
188 | $this->loadFixtureFiles([ |
|
189 | '@StarkerxpUtilisateurBundle/Tests/DataFixtures/UtilisateurManager/DefaultUtilisateur.yml', |
|
190 | ]); |
|
191 | $client = $this->getAuthClient(); |
|
192 | $client->request('GET', '/api/templates', ["filter_erreur" => "+h"]); |
|
193 | $response = $client->getResponse(); |
|
194 | $this->assertEquals(400, $response->getStatusCode()); |
|
195 | } |
|
196 | ||
197 | /** |
|
198 | * @group template |
|
@@ 247-256 (lines=10) @@ | ||
244 | * @group get |
|
245 | * @group controller |
|
246 | */ |
|
247 | public function testGetInvalide() |
|
248 | { |
|
249 | $this->loadFixtureFiles([ |
|
250 | '@StarkerxpUtilisateurBundle/Tests/DataFixtures/UtilisateurManager/DefaultUtilisateur.yml', |
|
251 | ]); |
|
252 | $client = $this->getAuthClient(); |
|
253 | $client->request('GET', '/api/templates/500', ["filter_erreur" => "+h"]); |
|
254 | $response = $client->getResponse(); |
|
255 | $this->assertEquals(400, $response->getStatusCode()); |
|
256 | } |
|
257 | ||
258 | /** |
|
259 | * @group template |
@@ 38-45 (lines=8) @@ | ||
35 | * @group post |
|
36 | * @group controller |
|
37 | */ |
|
38 | public function testPostInvalide() |
|
39 | { |
|
40 | $this->loadFixtureFiles(['@StarkerxpUtilisateurBundle/Tests/DataFixtures/UtilisateurManager/DefaultUtilisateur.yml',]); |
|
41 | $client = $this->getAuthClient(); |
|
42 | $client->request('POST', '/api/campagnes', []); |
|
43 | $response = $client->getResponse(); |
|
44 | $this->assertEquals(400, $response->getStatusCode()); |
|
45 | } |
|
46 | ||
47 | ||
48 | /** |
|
@@ 243-254 (lines=12) @@ | ||
240 | * @group get |
|
241 | * @group controller |
|
242 | */ |
|
243 | public function testGetInvalide() |
|
244 | { |
|
245 | $this->loadFixtureFiles( |
|
246 | [ |
|
247 | '@StarkerxpUtilisateurBundle/Tests/DataFixtures/UtilisateurManager/DefaultUtilisateur.yml', |
|
248 | ] |
|
249 | ); |
|
250 | $client = $this->getAuthClient(); |
|
251 | $client->request('GET', '/api/campagnes/500', ["filter_erreur" => "+h"]); |
|
252 | $response = $client->getResponse(); |
|
253 | $this->assertEquals(400, $response->getStatusCode()); |
|
254 | } |
|
255 | ||
256 | /** |
|
257 | * @group campagne |
@@ 209-224 (lines=16) @@ | ||
206 | * @group cget |
|
207 | * @group controller |
|
208 | */ |
|
209 | public function testCGetInvalide() |
|
210 | { |
|
211 | $this->loadFixtureFiles([ |
|
212 | '@StarkerxpUtilisateurBundle/Tests/DataFixtures/UtilisateurManager/DefaultUtilisateur.yml', |
|
213 | ]); |
|
214 | $url = $this->generateUrl( |
|
215 | 'starkerxp_lead.lead.cget', |
|
216 | [ |
|
217 | ||
218 | ] |
|
219 | ); |
|
220 | $client = $this->getAuthClient(); |
|
221 | $client->request('GET', $url, ["filter_erreur" => "+h"]); |
|
222 | $response = $client->getResponse(); |
|
223 | $this->assertEquals(400, $response->getStatusCode()); |
|
224 | } |
|
225 | ||
226 | /** |
|
227 | * @group lead |