diff options
-rw-r--r-- | src/Wallabag/ApiBundle/Controller/SearchRestController.php | 6 | ||||
-rw-r--r-- | tests/Wallabag/ApiBundle/Controller/SearchRestControllerTest.php | 7 |
2 files changed, 2 insertions, 11 deletions
diff --git a/src/Wallabag/ApiBundle/Controller/SearchRestController.php b/src/Wallabag/ApiBundle/Controller/SearchRestController.php index c0b2cb24..6620107d 100644 --- a/src/Wallabag/ApiBundle/Controller/SearchRestController.php +++ b/src/Wallabag/ApiBundle/Controller/SearchRestController.php | |||
@@ -10,13 +10,7 @@ use Pagerfanta\Adapter\DoctrineORMAdapter; | |||
10 | use Pagerfanta\Pagerfanta; | 10 | use Pagerfanta\Pagerfanta; |
11 | use Symfony\Component\HttpFoundation\JsonResponse; | 11 | use Symfony\Component\HttpFoundation\JsonResponse; |
12 | use Symfony\Component\HttpFoundation\Request; | 12 | use Symfony\Component\HttpFoundation\Request; |
13 | use Symfony\Component\HttpFoundation\Response; | ||
14 | use Symfony\Component\HttpKernel\Exception\HttpException; | ||
15 | use Symfony\Component\Routing\Generator\UrlGeneratorInterface; | 13 | use Symfony\Component\Routing\Generator\UrlGeneratorInterface; |
16 | use Wallabag\CoreBundle\Entity\Entry; | ||
17 | use Wallabag\CoreBundle\Entity\Tag; | ||
18 | use Wallabag\CoreBundle\Event\EntryDeletedEvent; | ||
19 | use Wallabag\CoreBundle\Event\EntrySavedEvent; | ||
20 | 14 | ||
21 | class SearchRestController extends WallabagRestController | 15 | class SearchRestController extends WallabagRestController |
22 | { | 16 | { |
diff --git a/tests/Wallabag/ApiBundle/Controller/SearchRestControllerTest.php b/tests/Wallabag/ApiBundle/Controller/SearchRestControllerTest.php index 5900ae53..f096f21b 100644 --- a/tests/Wallabag/ApiBundle/Controller/SearchRestControllerTest.php +++ b/tests/Wallabag/ApiBundle/Controller/SearchRestControllerTest.php | |||
@@ -4,9 +4,6 @@ namespace Tests\Wallabag\ApiBundle\Controller; | |||
4 | 4 | ||
5 | use Tests\Wallabag\ApiBundle\WallabagApiTestCase; | 5 | use Tests\Wallabag\ApiBundle\WallabagApiTestCase; |
6 | use Wallabag\CoreBundle\Entity\Entry; | 6 | use Wallabag\CoreBundle\Entity\Entry; |
7 | use Wallabag\CoreBundle\Entity\Tag; | ||
8 | use Wallabag\CoreBundle\Helper\ContentProxy; | ||
9 | use Wallabag\UserBundle\Entity\User; | ||
10 | 7 | ||
11 | class SearchRestControllerTest extends WallabagApiTestCase | 8 | class SearchRestControllerTest extends WallabagApiTestCase |
12 | { | 9 | { |
@@ -15,7 +12,7 @@ class SearchRestControllerTest extends WallabagApiTestCase | |||
15 | $this->client->request('GET', '/api/search', [ | 12 | $this->client->request('GET', '/api/search', [ |
16 | 'page' => 1, | 13 | 'page' => 1, |
17 | 'perPage' => 2, | 14 | 'perPage' => 2, |
18 | 'term' => 'entry' // 6 results | 15 | 'term' => 'entry', // 6 results |
19 | ]); | 16 | ]); |
20 | 17 | ||
21 | $this->assertSame(200, $this->client->getResponse()->getStatusCode()); | 18 | $this->assertSame(200, $this->client->getResponse()->getStatusCode()); |
@@ -45,7 +42,7 @@ class SearchRestControllerTest extends WallabagApiTestCase | |||
45 | public function testGetSearchWithNoLimit() | 42 | public function testGetSearchWithNoLimit() |
46 | { | 43 | { |
47 | $this->client->request('GET', '/api/search', [ | 44 | $this->client->request('GET', '/api/search', [ |
48 | 'term' => 'entry' | 45 | 'term' => 'entry', |
49 | ]); | 46 | ]); |
50 | 47 | ||
51 | $this->assertSame(200, $this->client->getResponse()->getStatusCode()); | 48 | $this->assertSame(200, $this->client->getResponse()->getStatusCode()); |