summaryrefslogtreecommitdiffstats
path: root/tests/unit/businesslayer/ItemBusinessLayerTest.php
diff options
context:
space:
mode:
Diffstat (limited to 'tests/unit/businesslayer/ItemBusinessLayerTest.php')
-rw-r--r--tests/unit/businesslayer/ItemBusinessLayerTest.php11
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/unit/businesslayer/ItemBusinessLayerTest.php b/tests/unit/businesslayer/ItemBusinessLayerTest.php
index e32a3b308..2094456b7 100644
--- a/tests/unit/businesslayer/ItemBusinessLayerTest.php
+++ b/tests/unit/businesslayer/ItemBusinessLayerTest.php
@@ -248,6 +248,17 @@ class ItemBusinessLayerTest extends \OCA\AppFramework\Utility\TestUtility {
}
+ public function testStarDoesNotExist(){
+
+ $this->setExpectedException('\OCA\News\BusinessLayer\BusinessLayerException');
+ $this->mapper->expects($this->once())
+ ->method('findByGuidHash')
+ ->will($this->throwException(new DoesNotExistException('')));
+
+ $this->itemBusinessLayer->star(1, 'hash', true, $this->user);
+ }
+
+
public function testReadFeed(){
$feedId = 3;
$highestItemId = 6;