summaryrefslogtreecommitdiffstats
path: root/tests/Unit/Db/ItemMapperAfterTest.php
diff options
context:
space:
mode:
Diffstat (limited to 'tests/Unit/Db/ItemMapperAfterTest.php')
-rw-r--r--tests/Unit/Db/ItemMapperAfterTest.php28
1 files changed, 24 insertions, 4 deletions
diff --git a/tests/Unit/Db/ItemMapperAfterTest.php b/tests/Unit/Db/ItemMapperAfterTest.php
index 5b0475522..68bad19dc 100644
--- a/tests/Unit/Db/ItemMapperAfterTest.php
+++ b/tests/Unit/Db/ItemMapperAfterTest.php
@@ -134,7 +134,7 @@ class ItemMapperAfterTest extends MapperTestUtility
['feeds.user_id = :userId'],
['feeds.id = :feedId'],
['feeds.deleted_at = 0'],
- ['items.unread = 1']
+ ['items.unread = :unread']
)
->will($this->returnSelf());
@@ -147,6 +147,11 @@ class ItemMapperAfterTest extends MapperTestUtility
])
->will($this->returnSelf());
+ $this->builder->expects($this->exactly(1))
+ ->method('setParameter')
+ ->with('unread', true)
+ ->will($this->returnSelf());
+
$this->builder->expects($this->once())
->method('orderBy')
->with('items.last_modified', 'DESC')
@@ -271,7 +276,7 @@ class ItemMapperAfterTest extends MapperTestUtility
['feeds.user_id = :userId'],
['feeds.deleted_at = 0'],
['folders.id = :folderId'],
- ['items.unread = 1']
+ ['items.unread = :unread']
)
->will($this->returnSelf());
@@ -284,6 +289,11 @@ class ItemMapperAfterTest extends MapperTestUtility
])
->will($this->returnSelf());
+ $this->builder->expects($this->exactly(1))
+ ->method('setParameter')
+ ->with('unread', true)
+ ->will($this->returnSelf());
+
$this->builder->expects($this->once())
->method('orderBy')
->with('items.last_modified', 'DESC')
@@ -336,7 +346,7 @@ class ItemMapperAfterTest extends MapperTestUtility
['items.last_modified >= :updatedSince'],
['feeds.deleted_at = 0'],
['feeds.user_id = :userId'],
- ['items.unread = 1']
+ ['items.unread = :unread']
)
->will($this->returnSelf());
@@ -348,6 +358,11 @@ class ItemMapperAfterTest extends MapperTestUtility
])
->will($this->returnSelf());
+ $this->builder->expects($this->exactly(1))
+ ->method('setParameter')
+ ->with('unread', true)
+ ->will($this->returnSelf());
+
$this->builder->expects($this->once())
->method('orderBy')
->with('items.last_modified', 'DESC')
@@ -400,7 +415,7 @@ class ItemMapperAfterTest extends MapperTestUtility
['items.last_modified >= :updatedSince'],
['feeds.deleted_at = 0'],
['feeds.user_id = :userId'],
- ['items.starred = 1']
+ ['items.starred = :starred']
)
->will($this->returnSelf());
@@ -412,6 +427,11 @@ class ItemMapperAfterTest extends MapperTestUtility
])
->will($this->returnSelf());
+ $this->builder->expects($this->exactly(1))
+ ->method('setParameter')
+ ->with('starred', true)
+ ->will($this->returnSelf());
+
$this->builder->expects($this->once())
->method('orderBy')
->with('items.last_modified', 'DESC')