summaryrefslogtreecommitdiffstats
path: root/tests/Unit/Service/FeedServiceTest.php
diff options
context:
space:
mode:
Diffstat (limited to 'tests/Unit/Service/FeedServiceTest.php')
-rw-r--r--tests/Unit/Service/FeedServiceTest.php14
1 files changed, 8 insertions, 6 deletions
diff --git a/tests/Unit/Service/FeedServiceTest.php b/tests/Unit/Service/FeedServiceTest.php
index d56d732a2..fd3dd1805 100644
--- a/tests/Unit/Service/FeedServiceTest.php
+++ b/tests/Unit/Service/FeedServiceTest.php
@@ -22,8 +22,10 @@ use OCA\News\Db\Item;
use OCA\News\Fetcher\Fetcher;
use OCA\News\Fetcher\FetcherException;
+use PHPUnit\Framework\TestCase;
-class FeedServiceTest extends \PHPUnit_Framework_TestCase
+
+class FeedServiceTest extends TestCase
{
private $feedMapper;
@@ -115,7 +117,7 @@ class FeedServiceTest extends \PHPUnit_Framework_TestCase
->method('fetch')
->with($this->equalTo($url))
->will($this->throwException($ex));
- $this->setExpectedException(
+ $this->expectException(
'\OCA\News\Service\ServiceNotFoundException'
);
$this->feedService->create($url, 1, $this->user);
@@ -622,7 +624,7 @@ class FeedServiceTest extends \PHPUnit_Framework_TestCase
)
->will($this->throwException($ex));
- $this->setExpectedException(
+ $this->expectException(
'\OCA\News\Service\ServiceNotFoundException'
);
$this->feedService->update($feed->getId(), $this->user);
@@ -659,7 +661,7 @@ class FeedServiceTest extends \PHPUnit_Framework_TestCase
)
->will($this->throwException($ex));
- $this->setExpectedException(
+ $this->expectException(
'OCP\AppFramework\Db\DoesNotExistException'
);
$this->feedService->update($feed->getId(), $this->user);
@@ -715,7 +717,7 @@ class FeedServiceTest extends \PHPUnit_Framework_TestCase
)
->will($this->throwException($ex));
- $this->setExpectedException(
+ $this->expectException(
'\OCA\News\Service\ServiceNotFoundException'
);
$this->feedService->update($feed->getId(), $this->user);
@@ -1121,7 +1123,7 @@ class FeedServiceTest extends \PHPUnit_Framework_TestCase
)
->will($this->throwException(new DoesNotExistException('')));
- $this->setExpectedException(
+ $this->expectException(
'\OCA\News\Service\ServiceNotFoundException'
);