summaryrefslogtreecommitdiffstats
path: root/tests/lib
diff options
context:
space:
mode:
authorBjoern Schiessle <bjoern@schiessle.org>2017-07-27 16:52:28 +0200
committerRoeland Jago Douma <roeland@famdouma.nl>2017-08-10 14:27:35 +0200
commitbae5be3dc14085a5061cd38e74c07453ed19b66b (patch)
treecf835b8139875131dcb1242ea37f7d29a862f9c7 /tests/lib
parent9524badccc6fd1e9d423f8dd8316b32ea576863b (diff)
downloadnextcloud-server-bae5be3dc14085a5061cd38e74c07453ed19b66b.tar.gz
nextcloud-server-bae5be3dc14085a5061cd38e74c07453ed19b66b.zip
add prefix to user and system keys to avoid name collisions
Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
Diffstat (limited to 'tests/lib')
-rw-r--r--tests/lib/Security/IdentityProof/ManagerTest.php10
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/lib/Security/IdentityProof/ManagerTest.php b/tests/lib/Security/IdentityProof/ManagerTest.php
index 5ab9ce63fb8..290e7be5c94 100644
--- a/tests/lib/Security/IdentityProof/ManagerTest.php
+++ b/tests/lib/Security/IdentityProof/ManagerTest.php
@@ -119,7 +119,7 @@ class ManagerTest extends TestCase {
$this->appData
->expects($this->once())
->method('getFolder')
- ->with('MyUid')
+ ->with('user-MyUid')
->willReturn($folder);
$expected = new Key('MyPublicKey', 'MyPrivateKey');
@@ -135,7 +135,7 @@ class ManagerTest extends TestCase {
$this->appData
->expects($this->at(0))
->method('getFolder')
- ->with('MyUid')
+ ->with('user-MyUid')
->willThrowException(new \Exception());
$this->manager
->expects($this->once())
@@ -144,7 +144,7 @@ class ManagerTest extends TestCase {
$this->appData
->expects($this->at(1))
->method('newFolder')
- ->with('MyUid');
+ ->with('user-MyUid');
$folder = $this->createMock(ISimpleFolder::class);
$this->crypto
->expects($this->once())
@@ -174,7 +174,7 @@ class ManagerTest extends TestCase {
$this->appData
->expects($this->at(2))
->method('getFolder')
- ->with('MyUid')
+ ->with('user-MyUid')
->willReturn($folder);
@@ -203,7 +203,7 @@ class ManagerTest extends TestCase {
$this->config->expects($this->once())->method('getSystemValue')
->with('instanceid', null)->willReturn('instanceId');
- $manager->expects($this->once())->method('retrieveKey')->with('instanceId')
+ $manager->expects($this->once())->method('retrieveKey')->with('system-instanceId')
->willReturn($key);
$this->assertSame($key, $manager->getSystemKey());