aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Wallabag/CoreBundle/Tests
diff options
context:
space:
mode:
authorNicolas LÅ“uillet <nicolas@loeuillet.org>2015-02-10 20:07:55 +0100
committerNicolas LÅ“uillet <nicolas@loeuillet.org>2015-02-11 06:27:04 +0100
commitf5deb024a2dd5a2cb27263a51f4653609407597e (patch)
tree83e2761fbbd64182bb9598148e2ee3835c039594 /src/Wallabag/CoreBundle/Tests
parent68c6f1bd7fbf2f01730ee38b1291251494c80eb0 (diff)
downloadwallabag-f5deb024a2dd5a2cb27263a51f4653609407597e.tar.gz
wallabag-f5deb024a2dd5a2cb27263a51f4653609407597e.tar.zst
wallabag-f5deb024a2dd5a2cb27263a51f4653609407597e.zip
add test for api/salts
Diffstat (limited to 'src/Wallabag/CoreBundle/Tests')
-rw-r--r--src/Wallabag/CoreBundle/Tests/Controller/WallabagRestControllerTest.php15
1 files changed, 13 insertions, 2 deletions
diff --git a/src/Wallabag/CoreBundle/Tests/Controller/WallabagRestControllerTest.php b/src/Wallabag/CoreBundle/Tests/Controller/WallabagRestControllerTest.php
index 0949b92d..d9e6a161 100644
--- a/src/Wallabag/CoreBundle/Tests/Controller/WallabagRestControllerTest.php
+++ b/src/Wallabag/CoreBundle/Tests/Controller/WallabagRestControllerTest.php
@@ -6,7 +6,18 @@ use Symfony\Bundle\FrameworkBundle\Test\WebTestCase;
6 6
7class WallabagRestControllerTest extends WebTestCase 7class WallabagRestControllerTest extends WebTestCase
8{ 8{
9 public function testEmptyGetEntries() { 9 public function testGetSalt()
10 {
11 $client = $this->createClient();
12 $client->request('GET', '/api/salts/admin.json');
13 $this->assertEquals(200, $client->getResponse()->getStatusCode());
14
15 $client->request('GET', '/api/salts/notfound.json');
16 $this->assertEquals(404, $client->getResponse()->getStatusCode());
17 }
18
19 public function testEmptyGetEntries()
20 {
10 $client = $this->createClient(); 21 $client = $this->createClient();
11 $client->request('GET', '/api/entries'); 22 $client->request('GET', '/api/entries');
12 $this->assertTrue($client->getResponse()->isOk()); 23 $this->assertTrue($client->getResponse()->isOk());
@@ -19,4 +30,4 @@ class WallabagRestControllerTest extends WebTestCase
19 ); 30 );
20 $this->assertEquals('[]', $client->getResponse()->getContent()); 31 $this->assertEquals('[]', $client->getResponse()->getContent());
21 } 32 }
22} \ No newline at end of file 33}