| @@ 153-161 (lines=9) @@ | ||
| 150 | * @group cget |
|
| 151 | * @group controller |
|
| 152 | */ |
|
| 153 | public function testCGetValideSansResultat() |
|
| 154 | { |
|
| 155 | $client = static::createClient(); |
|
| 156 | $client->request('GET', '/templates', []); |
|
| 157 | $response = $client->getResponse(); |
|
| 158 | $this->assertEquals(200, $response->getStatusCode()); |
|
| 159 | $body = json_decode($response->getContent(), true); |
|
| 160 | $this->assertCount(0, $body); |
|
| 161 | } |
|
| 162 | ||
| 163 | /** |
|
| 164 | * @group template |
|
| @@ 205-213 (lines=9) @@ | ||
| 202 | * @group get |
|
| 203 | * @group controller |
|
| 204 | */ |
|
| 205 | public function testGetValideSansResultat() |
|
| 206 | { |
|
| 207 | $client = static::createClient(); |
|
| 208 | $client->request('GET', '/templates/404', []); |
|
| 209 | $response = $client->getResponse(); |
|
| 210 | $this->assertEquals(404, $response->getStatusCode()); |
|
| 211 | $body = json_decode($response->getContent(), true); |
|
| 212 | $this->assertNotEmpty($body); |
|
| 213 | } |
|
| 214 | ||
| 215 | /** |
|
| 216 | * @group template |
|
| @@ 253-261 (lines=9) @@ | ||
| 250 | * @group delete |
|
| 251 | * @group controller |
|
| 252 | */ |
|
| 253 | public function testDeleteSansResultat() |
|
| 254 | { |
|
| 255 | $client = static::createClient(); |
|
| 256 | $client->request('DELETE', '/templates/404', []); |
|
| 257 | $response = $client->getResponse(); |
|
| 258 | $this->assertEquals(404, $response->getStatusCode()); |
|
| 259 | $body = json_decode($response->getContent(), true); |
|
| 260 | $this->assertNotEmpty($body); |
|
| 261 | } |
|
| 262 | } |
|
| 263 | ||