diff options
author | Roeland Jago Douma <roeland@famdouma.nl> | 2016-09-02 10:42:06 +0200 |
---|---|---|
committer | Morris Jobke <hey@morrisjobke.de> | 2016-09-06 09:29:27 +0200 |
commit | 327352e73a09f6a42335e7da14fb50583167c616 (patch) | |
tree | 909616ec9b898b64cb5d64068c11f00050f2db94 | |
parent | 9cd637487877212a29009a4be4039b8d4fc53e1e (diff) | |
download | nextcloud-server-327352e73a09f6a42335e7da14fb50583167c616.tar.gz nextcloud-server-327352e73a09f6a42335e7da14fb50583167c616.zip |
Fix getMock files_trashbin
-rw-r--r-- | apps/files_trashbin/tests/BackgroundJob/ExpireTrashTest.php | 6 | ||||
-rw-r--r-- | apps/files_trashbin/tests/TrashbinTest.php | 2 |
2 files changed, 5 insertions, 3 deletions
diff --git a/apps/files_trashbin/tests/BackgroundJob/ExpireTrashTest.php b/apps/files_trashbin/tests/BackgroundJob/ExpireTrashTest.php index d92984bbce9..4bf533194b4 100644 --- a/apps/files_trashbin/tests/BackgroundJob/ExpireTrashTest.php +++ b/apps/files_trashbin/tests/BackgroundJob/ExpireTrashTest.php @@ -24,15 +24,17 @@ namespace OCA\Files_Trashbin\Tests\BackgroundJob; use \OCA\Files_Trashbin\BackgroundJob\ExpireTrash; +use OCP\BackgroundJob\IJobList; +use OCP\IUserManager; class ExpireTrashTest extends \Test\TestCase { public function testConstructAndRun() { $backgroundJob = new ExpireTrash( - $this->getMock('OCP\IUserManager'), + $this->createMock(IUserManager::class), $this->getMockBuilder('OCA\Files_Trashbin\Expiration')->disableOriginalConstructor()->getMock() ); - $jobList = $this->getMock('\OCP\BackgroundJob\IJobList'); + $jobList = $this->createMock(IJobList::class); /** @var \OC\BackgroundJob\JobList $jobList */ $backgroundJob->execute($jobList); diff --git a/apps/files_trashbin/tests/TrashbinTest.php b/apps/files_trashbin/tests/TrashbinTest.php index cb5a9fed5bb..7e4cdb112e8 100644 --- a/apps/files_trashbin/tests/TrashbinTest.php +++ b/apps/files_trashbin/tests/TrashbinTest.php @@ -112,7 +112,7 @@ class TrashbinTest extends \Test\TestCase { \OC::$server->getAppManager()->enableApp('files_trashbin'); $config = \OC::$server->getConfig(); - $mockConfig = $this->getMock('\OCP\IConfig'); + $mockConfig = $this->createMock(\OCP\IConfig::class); $mockConfig->expects($this->any()) ->method('getSystemValue') ->will($this->returnCallback(function ($key, $default) use ($config) { |