1
0
Fork 0
mirror of https://github.com/wallabag/wallabag.git synced 2025-09-15 18:57:05 +00:00

Factorize sendResponse between Api controllers

And run newer cs fixer
This commit is contained in:
Jeremy Benoist 2018-10-24 20:11:45 +02:00
parent 9133bd02d1
commit 019e1acc49
No known key found for this signature in database
GPG key ID: BCA73962457ACC3C
4 changed files with 21 additions and 41 deletions

View file

@ -3,7 +3,6 @@
namespace Tests\Wallabag\ApiBundle\Controller;
use Tests\Wallabag\ApiBundle\WallabagApiTestCase;
use Wallabag\CoreBundle\Entity\Entry;
class SearchRestControllerTest extends WallabagApiTestCase
{
@ -19,7 +18,7 @@ class SearchRestControllerTest extends WallabagApiTestCase
$content = json_decode($this->client->getResponse()->getContent(), true);
$this->assertGreaterThanOrEqual(1, count($content));
$this->assertGreaterThanOrEqual(1, \count($content));
$this->assertArrayHasKey('items', $content['_embedded']);
$this->assertGreaterThanOrEqual(0, $content['total']);
$this->assertSame(1, $content['page']);
@ -49,7 +48,7 @@ class SearchRestControllerTest extends WallabagApiTestCase
$content = json_decode($this->client->getResponse()->getContent(), true);
$this->assertGreaterThanOrEqual(1, count($content));
$this->assertGreaterThanOrEqual(1, \count($content));
$this->assertArrayHasKey('items', $content['_embedded']);
$this->assertGreaterThanOrEqual(0, $content['total']);
$this->assertSame(1, $content['page']);