diff --git a/src/Wallabag/CoreBundle/Resources/views/Entry/entries.html.twig b/src/Wallabag/CoreBundle/Resources/views/Entry/entries.html.twig
index a794df0e5..118a2f4be 100644
--- a/src/Wallabag/CoreBundle/Resources/views/Entry/entries.html.twig
+++ b/src/Wallabag/CoreBundle/Resources/views/Entry/entries.html.twig
@@ -21,7 +21,7 @@
{% if entries is empty %}
diff --git a/src/Wallabag/CoreBundle/Tests/Controller/EntryControllerTest.php b/src/Wallabag/CoreBundle/Tests/Controller/EntryControllerTest.php
index 86a19f616..5f0a60763 100644
--- a/src/Wallabag/CoreBundle/Tests/Controller/EntryControllerTest.php
+++ b/src/Wallabag/CoreBundle/Tests/Controller/EntryControllerTest.php
@@ -276,7 +276,7 @@ class EntryControllerTest extends WallabagCoreTestCase
$crawler = $client->submit($form, $data);
- $this->assertCount(4, $crawler->filter('div[class=entry]'));
+ $this->assertCount(5, $crawler->filter('div[class=entry]'));
$data = array(
'entry_filter[createdAt][left_date]' => '01/01/1970',
@@ -307,6 +307,14 @@ class EntryControllerTest extends WallabagCoreTestCase
$crawler = $client->request('GET', 'unread/list'.$parameters);
$this->assertContains($parameters, $client->getResponse()->getContent());
+
+ // reset pagination
+ $crawler = $client->request('GET', '/config');
+ $form = $crawler->filter('button[id=config_save]')->form();
+ $data = array(
+ 'config[items_per_page]' => '12',
+ );
+ $client->submit($form, $data);
}
public function testFilterOnDomainName()
@@ -331,4 +339,25 @@ class EntryControllerTest extends WallabagCoreTestCase
$crawler = $client->submit($form, $data);
$this->assertCount(0, $crawler->filter('div[class=entry]'));
}
+
+ public function testFilterOnStatus()
+ {
+ $this->logInAs('admin');
+ $client = $this->getClient();
+
+ $crawler = $client->request('GET', '/unread/list');
+ $form = $crawler->filter('button[id=submit-filter]')->form();
+ $form['entry_filter[isArchived]']->tick();
+ $form['entry_filter[isStarred]']->untick();
+
+ $crawler = $client->submit($form);
+ $this->assertCount(1, $crawler->filter('div[class=entry]'));
+
+ $form = $crawler->filter('button[id=submit-filter]')->form();
+ $form['entry_filter[isArchived]']->untick();
+ $form['entry_filter[isStarred]']->tick();
+
+ $crawler = $client->submit($form);
+ $this->assertCount(1, $crawler->filter('div[class=entry]'));
+ }
}