summaryrefslogtreecommitdiffstats
path: root/tests/lib/Encryption/UtilTest.php
diff options
context:
space:
mode:
authorRoeland Jago Douma <roeland@famdouma.nl>2016-09-07 19:51:45 +0200
committerRoeland Jago Douma <roeland@famdouma.nl>2016-09-07 20:42:37 +0200
commit4da1ee99d687d27f82e32f53af74ff52a35c36f9 (patch)
tree0ec59946f9837987d68b337aac11c59a2ec288e9 /tests/lib/Encryption/UtilTest.php
parent9ea2153e9be84a7a0bafc469289b66669bba9852 (diff)
downloadnextcloud-server-4da1ee99d687d27f82e32f53af74ff52a35c36f9.tar.gz
nextcloud-server-4da1ee99d687d27f82e32f53af74ff52a35c36f9.zip
Fix getMock Encryption
Diffstat (limited to 'tests/lib/Encryption/UtilTest.php')
-rw-r--r--tests/lib/Encryption/UtilTest.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/lib/Encryption/UtilTest.php b/tests/lib/Encryption/UtilTest.php
index ec316a9f05a..609f6ae1e68 100644
--- a/tests/lib/Encryption/UtilTest.php
+++ b/tests/lib/Encryption/UtilTest.php
@@ -3,6 +3,7 @@
namespace Test\Encryption;
use OC\Encryption\Util;
+use OCP\Encryption\IEncryptionModule;
use Test\TestCase;
class UtilTest extends TestCase {
@@ -77,7 +78,7 @@ class UtilTest extends TestCase {
*/
public function testCreateHeader($expected, $header, $moduleId) {
- $em = $this->getMock('\OCP\Encryption\IEncryptionModule');
+ $em = $this->createMock(IEncryptionModule::class);
$em->expects($this->any())->method('getId')->willReturn($moduleId);
$result = $this->util->createHeader($header, $em);
@@ -100,7 +101,7 @@ class UtilTest extends TestCase {
$header = array('header1' => 1, 'header2' => 2, 'oc_encryption_module' => 'foo');
- $em = $this->getMock('\OCP\Encryption\IEncryptionModule');
+ $em = $this->createMock(IEncryptionModule::class);
$em->expects($this->any())->method('getId')->willReturn('moduleId');
$this->util->createHeader($header, $em);