aboutsummaryrefslogtreecommitdiffstats
path: root/apps/encryption/tests/RecoveryTest.php
diff options
context:
space:
mode:
authorRoeland Jago Douma <roeland@famdouma.nl>2016-09-02 10:29:05 +0200
committerMorris Jobke <hey@morrisjobke.de>2016-09-06 09:29:27 +0200
commit0c154c1ed779ccd68ea67e3528fad36ad6ac9b34 (patch)
tree05a9f0d94c8730ed6de352b91a8db72c72ca957f /apps/encryption/tests/RecoveryTest.php
parent831179971cf2d693cc09e4a216387d107567a47e (diff)
downloadnextcloud-server-0c154c1ed779ccd68ea67e3528fad36ad6ac9b34.tar.gz
nextcloud-server-0c154c1ed779ccd68ea67e3528fad36ad6ac9b34.zip
Fix getMock encryption
Diffstat (limited to 'apps/encryption/tests/RecoveryTest.php')
-rw-r--r--apps/encryption/tests/RecoveryTest.php15
1 files changed, 10 insertions, 5 deletions
diff --git a/apps/encryption/tests/RecoveryTest.php b/apps/encryption/tests/RecoveryTest.php
index 477913a1a69..d73b5d48c91 100644
--- a/apps/encryption/tests/RecoveryTest.php
+++ b/apps/encryption/tests/RecoveryTest.php
@@ -27,7 +27,12 @@
namespace OCA\Encryption\Tests;
+use OC\Files\View;
use OCA\Encryption\Recovery;
+use OCP\Encryption\IFile;
+use OCP\Encryption\Keys\IStorage;
+use OCP\IConfig;
+use OCP\Security\ISecureRandom;
use Test\TestCase;
class RecoveryTest extends TestCase {
@@ -268,13 +273,13 @@ class RecoveryTest extends TestCase {
$this->cryptMock = $this->getMockBuilder('OCA\Encryption\Crypto\Crypt')->disableOriginalConstructor()->getMock();
/** @var \OCP\Security\ISecureRandom $randomMock */
- $randomMock = $this->getMock('OCP\Security\ISecureRandom');
+ $randomMock = $this->createMock(ISecureRandom::class);
$this->keyManagerMock = $this->getMockBuilder('OCA\Encryption\KeyManager')->disableOriginalConstructor()->getMock();
- $this->configMock = $this->getMock('OCP\IConfig');
+ $this->configMock = $this->createMock(IConfig::class);
/** @var \OCP\Encryption\Keys\IStorage $keyStorageMock */
- $keyStorageMock = $this->getMock('OCP\Encryption\Keys\IStorage');
- $this->fileMock = $this->getMock('OCP\Encryption\IFile');
- $this->viewMock = $this->getMock('OC\Files\View');
+ $keyStorageMock = $this->createMock(IStorage::class);
+ $this->fileMock = $this->createMock(IFile::class);
+ $this->viewMock = $this->createMock(View::class);
$this->configMock->expects($this->any())
->method('setAppValue')