summaryrefslogtreecommitdiffstats
path: root/apps/encryption/tests
diff options
context:
space:
mode:
authorClark Tomlinson <fallen013@gmail.com>2015-03-26 20:35:36 -0400
committerThomas Müller <thomas.mueller@tmit.eu>2015-04-07 13:30:27 +0200
commitd15c2e52b0576e7846a09fd84e0e10f3054623c6 (patch)
treef027d9cb18160353fe440e4eef48be8aa7cdea99 /apps/encryption/tests
parent2e00acda079644ce4eb61b8a3812b095df8d05e3 (diff)
downloadnextcloud-server-d15c2e52b0576e7846a09fd84e0e10f3054623c6.tar.gz
nextcloud-server-d15c2e52b0576e7846a09fd84e0e10f3054623c6.zip
cleanup and removing cachefactory
Diffstat (limited to 'apps/encryption/tests')
-rw-r--r--apps/encryption/tests/lib/KeyManagerTest.php15
1 files changed, 11 insertions, 4 deletions
diff --git a/apps/encryption/tests/lib/KeyManagerTest.php b/apps/encryption/tests/lib/KeyManagerTest.php
index 01c5e1d2d07..ed6048d7642 100644
--- a/apps/encryption/tests/lib/KeyManagerTest.php
+++ b/apps/encryption/tests/lib/KeyManagerTest.php
@@ -45,10 +45,15 @@ class KeyManagerTest extends TestCase {
$userMock
->method('getUID')
->will($this->returnValue('admin'));
- $cacheMock = $this->getMock('OCP\ICacheFactory');
+ $sessionMock = $this->getMock('OCP\ISession');
$logMock = $this->getMock('OCP\ILogger');
$this->userId = 'admin';
- $this->instance = new KeyManager($keyStorageMock, $cryptMock, $configMock, $userMock, $cacheMock, $logMock);
+ $this->instance = new KeyManager($keyStorageMock,
+ $cryptMock,
+ $configMock,
+ $userMock,
+ $sessionMock,
+ $logMock);
$this->dummyKeys = ['public' => 'randomweakpublickeyhere',
'private' => 'randomweakprivatekeyhere'];
@@ -87,14 +92,16 @@ class KeyManagerTest extends TestCase {
*/
public function testSetPublicKey() {
- $this->assertTrue($this->instance->setPublicKey($this->userId, $this->dummyKeys['public']));
+ $this->assertTrue($this->instance->setPublicKey($this->userId,
+ $this->dummyKeys['public']));
}
/**
*
*/
public function testSetPrivateKey() {
- $this->assertTrue($this->instance->setPrivateKey($this->userId, $this->dummyKeys['private']));
+ $this->assertTrue($this->instance->setPrivateKey($this->userId,
+ $this->dummyKeys['private']));
}
/**