diff options
Diffstat (limited to 'tests/Wallabag/CoreBundle')
-rw-r--r-- | tests/Wallabag/CoreBundle/Controller/EntryControllerTest.php | 14 | ||||
-rw-r--r-- | tests/Wallabag/CoreBundle/Helper/ContentProxyTest.php | 6 |
2 files changed, 17 insertions, 3 deletions
diff --git a/tests/Wallabag/CoreBundle/Controller/EntryControllerTest.php b/tests/Wallabag/CoreBundle/Controller/EntryControllerTest.php index f17dc97b..7cf28bfe 100644 --- a/tests/Wallabag/CoreBundle/Controller/EntryControllerTest.php +++ b/tests/Wallabag/CoreBundle/Controller/EntryControllerTest.php | |||
@@ -861,6 +861,20 @@ class EntryControllerTest extends WallabagCoreTestCase | |||
861 | $this->assertCount(1, $crawler->filter('div[class=entry]')); | 861 | $this->assertCount(1, $crawler->filter('div[class=entry]')); |
862 | } | 862 | } |
863 | 863 | ||
864 | public function testFilterOnIsPublic() | ||
865 | { | ||
866 | $this->logInAs('admin'); | ||
867 | $this->useTheme('baggy'); | ||
868 | $client = $this->getClient(); | ||
869 | |||
870 | $crawler = $client->request('GET', '/unread/list'); | ||
871 | $form = $crawler->filter('button[id=submit-filter]')->form(); | ||
872 | $form['entry_filter[isPublic]']->tick(); | ||
873 | |||
874 | $crawler = $client->submit($form); | ||
875 | $this->assertCount(0, $crawler->filter('div[class=entry]')); | ||
876 | } | ||
877 | |||
864 | public function testPreviewPictureFilter() | 878 | public function testPreviewPictureFilter() |
865 | { | 879 | { |
866 | $this->logInAs('admin'); | 880 | $this->logInAs('admin'); |
diff --git a/tests/Wallabag/CoreBundle/Helper/ContentProxyTest.php b/tests/Wallabag/CoreBundle/Helper/ContentProxyTest.php index 95dd75ba..dbddbc5c 100644 --- a/tests/Wallabag/CoreBundle/Helper/ContentProxyTest.php +++ b/tests/Wallabag/CoreBundle/Helper/ContentProxyTest.php | |||
@@ -206,7 +206,7 @@ class ContentProxyTest extends \PHPUnit_Framework_TestCase | |||
206 | $this->assertEquals('http://1.1.1.1', $entry->getUrl()); | 206 | $this->assertEquals('http://1.1.1.1', $entry->getUrl()); |
207 | $this->assertEquals('this is my title', $entry->getTitle()); | 207 | $this->assertEquals('this is my title', $entry->getTitle()); |
208 | $this->assertContains('this is my content', $entry->getContent()); | 208 | $this->assertContains('this is my content', $entry->getContent()); |
209 | $this->assertEmpty($entry->getPreviewPicture()); | 209 | $this->assertNull($entry->getPreviewPicture()); |
210 | $this->assertEquals('text/html', $entry->getMimetype()); | 210 | $this->assertEquals('text/html', $entry->getMimetype()); |
211 | $this->assertEquals('fr', $entry->getLanguage()); | 211 | $this->assertEquals('fr', $entry->getLanguage()); |
212 | $this->assertEquals('200', $entry->getHttpStatus()); | 212 | $this->assertEquals('200', $entry->getHttpStatus()); |
@@ -252,7 +252,7 @@ class ContentProxyTest extends \PHPUnit_Framework_TestCase | |||
252 | $this->assertEquals('this is my title', $entry->getTitle()); | 252 | $this->assertEquals('this is my title', $entry->getTitle()); |
253 | $this->assertContains('this is my content', $entry->getContent()); | 253 | $this->assertContains('this is my content', $entry->getContent()); |
254 | $this->assertEquals('text/html', $entry->getMimetype()); | 254 | $this->assertEquals('text/html', $entry->getMimetype()); |
255 | $this->assertEmpty($entry->getLanguage()); | 255 | $this->assertNull($entry->getLanguage()); |
256 | $this->assertEquals('200', $entry->getHttpStatus()); | 256 | $this->assertEquals('200', $entry->getHttpStatus()); |
257 | $this->assertEquals(4.0, $entry->getReadingTime()); | 257 | $this->assertEquals(4.0, $entry->getReadingTime()); |
258 | $this->assertEquals('1.1.1.1', $entry->getDomainName()); | 258 | $this->assertEquals('1.1.1.1', $entry->getDomainName()); |
@@ -300,7 +300,7 @@ class ContentProxyTest extends \PHPUnit_Framework_TestCase | |||
300 | $this->assertEquals('http://1.1.1.1', $entry->getUrl()); | 300 | $this->assertEquals('http://1.1.1.1', $entry->getUrl()); |
301 | $this->assertEquals('this is my title', $entry->getTitle()); | 301 | $this->assertEquals('this is my title', $entry->getTitle()); |
302 | $this->assertContains('this is my content', $entry->getContent()); | 302 | $this->assertContains('this is my content', $entry->getContent()); |
303 | $this->assertEmpty($entry->getPreviewPicture()); | 303 | $this->assertNull($entry->getPreviewPicture()); |
304 | $this->assertEquals('text/html', $entry->getMimetype()); | 304 | $this->assertEquals('text/html', $entry->getMimetype()); |
305 | $this->assertEquals('fr', $entry->getLanguage()); | 305 | $this->assertEquals('fr', $entry->getLanguage()); |
306 | $this->assertEquals('200', $entry->getHttpStatus()); | 306 | $this->assertEquals('200', $entry->getHttpStatus()); |