summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/unit/businesslayer/FeedBusinessLayerTest.php20
1 files changed, 20 insertions, 0 deletions
diff --git a/tests/unit/businesslayer/FeedBusinessLayerTest.php b/tests/unit/businesslayer/FeedBusinessLayerTest.php
index 0b147c837..465dda8cb 100644
--- a/tests/unit/businesslayer/FeedBusinessLayerTest.php
+++ b/tests/unit/businesslayer/FeedBusinessLayerTest.php
@@ -480,6 +480,26 @@ class FeedBusinessLayerTest extends \OCA\AppFramework\Utility\TestUtility {
}
+ public function testUpdateDoesntUpdateIfFeedIsPrevented() {
+ $feedId = 3;
+ $folderId = 4;
+ $feed = new Feed();
+ $feed->setFolderId(16);
+ $feed->setId($feedId);
+ $feed->setPreventUpdate(true);
+
+ $this->mapper->expects($this->once())
+ ->method('find')
+ ->with($this->equalTo($feedId),
+ $this->equalTo($this->user))
+ ->will($this->returnValue($feed));
+ $this->fetcher->expects($this->never())
+ ->method('fetch');
+
+ $this->businessLayer->update($feedId, $this->user);
+ }
+
+
public function testMove(){
$feedId = 3;
$folderId = 4;