diff options
author | John Molakvoæ <skjnldsv@users.noreply.github.com> | 2018-10-02 14:44:52 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-10-02 14:44:52 +0200 |
commit | 13fb06e5141e3433ab502565527324ad1e924d00 (patch) | |
tree | c0eedead6788614b886940f892f23c6537368a19 /tests/Unit/Db | |
parent | c36b0a95685cb0daa3fce9d743b7610a5cfe50ed (diff) | |
parent | fa5f07ba9a77959796c3c7a4851f2f2fe1051afa (diff) |
Merge pull request #341 from SMillerDev/master
Put back old tests for stable nextcloud version and bump dependencies
Diffstat (limited to 'tests/Unit/Db')
-rw-r--r-- | tests/Unit/Db/FeedTest.php | 4 | ||||
-rw-r--r-- | tests/Unit/Db/FolderMapperTest.php | 4 | ||||
-rw-r--r-- | tests/Unit/Db/FolderTest.php | 3 | ||||
-rw-r--r-- | tests/Unit/Db/ItemTest.php | 4 | ||||
-rw-r--r-- | tests/Unit/Db/MapperFactoryTest.php | 4 | ||||
-rw-r--r-- | tests/Unit/Db/MapperTestUtility.php | 3 |
6 files changed, 13 insertions, 9 deletions
diff --git a/tests/Unit/Db/FeedTest.php b/tests/Unit/Db/FeedTest.php index 5e4e2a5a5..961e1d9b7 100644 --- a/tests/Unit/Db/FeedTest.php +++ b/tests/Unit/Db/FeedTest.php @@ -13,10 +13,10 @@ namespace OCA\News\Tests\Unit\Db; - +use PHPUnit\Framework\TestCase; use OCA\News\Db\Feed; -class FeedTest extends \PHPUnit_Framework_TestCase +class FeedTest extends TestCase { diff --git a/tests/Unit/Db/FolderMapperTest.php b/tests/Unit/Db/FolderMapperTest.php index bf7b1cae0..c8230ff0f 100644 --- a/tests/Unit/Db/FolderMapperTest.php +++ b/tests/Unit/Db/FolderMapperTest.php @@ -70,7 +70,7 @@ class FolderMapperTest extends MapperTestUtility $this->setMapperResult($sql, [$id, $userId]); - $this->setExpectedException( + $this->expectException( '\OCP\AppFramework\Db\DoesNotExistException' ); $this->folderMapper->find($id, $userId); @@ -88,7 +88,7 @@ class FolderMapperTest extends MapperTestUtility $this->setMapperResult($sql, [$id, $userId], $rows); - $this->setExpectedException( + $this->expectException( '\OCP\AppFramework\Db\MultipleObjectsReturnedException' ); $this->folderMapper->find($id, $userId); diff --git a/tests/Unit/Db/FolderTest.php b/tests/Unit/Db/FolderTest.php index 4db59cef2..a3445ea2e 100644 --- a/tests/Unit/Db/FolderTest.php +++ b/tests/Unit/Db/FolderTest.php @@ -14,8 +14,9 @@ namespace OCA\News\Tests\Unit\Db; use OCA\News\Db\Folder; +use PHPUnit\Framework\TestCase; -class FolderTest extends \PHPUnit_Framework_TestCase +class FolderTest extends TestCase { diff --git a/tests/Unit/Db/ItemTest.php b/tests/Unit/Db/ItemTest.php index f86c2c8a9..4c725b827 100644 --- a/tests/Unit/Db/ItemTest.php +++ b/tests/Unit/Db/ItemTest.php @@ -16,7 +16,9 @@ namespace OCA\News\Tests\Unit\Db; use OCA\News\Db\Feed; use OCA\News\Db\Item; -class ItemTest extends \PHPUnit_Framework_TestCase +use PHPUnit\Framework\TestCase; + +class ItemTest extends TestCase { /** diff --git a/tests/Unit/Db/MapperFactoryTest.php b/tests/Unit/Db/MapperFactoryTest.php index 94a49f850..697a62bee 100644 --- a/tests/Unit/Db/MapperFactoryTest.php +++ b/tests/Unit/Db/MapperFactoryTest.php @@ -16,14 +16,14 @@ namespace OCA\News\Tests\Unit\Db; use OCA\News\Db\ItemMapper; use OCA\News\Db\MapperFactory; use OCA\News\Utility\Time; -use PHPUnit_Framework_TestCase; +use PHPUnit\Framework\TestCase; use OCP\IDBConnection; use OCA\News\Db\Mysql\ItemMapper as MysqlMapper; -class MapperFactoryTest extends PHPUnit_Framework_TestCase +class MapperFactoryTest extends TestCase { private $db; diff --git a/tests/Unit/Db/MapperTestUtility.php b/tests/Unit/Db/MapperTestUtility.php index caef6527c..0c45a0bba 100644 --- a/tests/Unit/Db/MapperTestUtility.php +++ b/tests/Unit/Db/MapperTestUtility.php @@ -23,10 +23,11 @@ namespace OCA\News\Tests\Unit\Db; +use PHPUnit\Framework\TestCase; /** * Simple utility class for testing mappers */ -abstract class MapperTestUtility extends \PHPUnit_Framework_TestCase +abstract class MapperTestUtility extends TestCase { protected $db; private $query; |