3 namespace Tests\Wallabag\ApiBundle\Controller
;
5 use Tests\Wallabag\ApiBundle\WallabagApiTestCase
;
7 class WallabagRestControllerTest
extends WallabagApiTestCase
9 public function testGetVersion()
11 // create a new client instead of using $this->client to be sure client isn't authenticated
12 $client = static::createClient();
13 $client->request('GET', '/api/version');
15 $this->assertSame(200, $client->getResponse()->getStatusCode());
17 $content = json_decode($client->getResponse()->getContent(), true);
19 $this->assertSame($client->getContainer()->getParameter('wallabag_core.version'), $content);