summaryrefslogtreecommitdiffstats
path: root/apps/encryption/tests
diff options
context:
space:
mode:
authorChristoph Wurst <ChristophWurst@users.noreply.github.com>2020-04-09 15:53:09 +0200
committerGitHub <noreply@github.com>2020-04-09 15:53:09 +0200
commitc56a273b39186c509c57ef6bec221d3c4e3d81d3 (patch)
treeb2e4095e763874699646c2c90e41785c99b6f247 /apps/encryption/tests
parentf0dd71ccd266ede38114d25be035abb3f2661fc8 (diff)
parentafbd9c4e6ed834e713039f2cff88ba3eec03dadb (diff)
downloadnextcloud-server-c56a273b39186c509c57ef6bec221d3c4e3d81d3.tar.gz
nextcloud-server-c56a273b39186c509c57ef6bec221d3c4e3d81d3.zip
Merge pull request #20383 from nextcloud/techdebt/function-spacing
Unify function spacing to PSR2 recommendation
Diffstat (limited to 'apps/encryption/tests')
-rw-r--r--apps/encryption/tests/Controller/SettingsControllerTest.php2
-rw-r--r--apps/encryption/tests/Controller/StatusControllerTest.php2
-rw-r--r--apps/encryption/tests/Crypto/CryptTest.php2
-rw-r--r--apps/encryption/tests/Crypto/EncryptAllTest.php2
-rw-r--r--apps/encryption/tests/Crypto/EncryptionTest.php10
-rw-r--r--apps/encryption/tests/KeyManagerTest.php6
6 files changed, 12 insertions, 12 deletions
diff --git a/apps/encryption/tests/Controller/SettingsControllerTest.php b/apps/encryption/tests/Controller/SettingsControllerTest.php
index 4ac26cde64c..160c9794613 100644
--- a/apps/encryption/tests/Controller/SettingsControllerTest.php
+++ b/apps/encryption/tests/Controller/SettingsControllerTest.php
@@ -86,7 +86,7 @@ class SettingsControllerTest extends TestCase {
$this->l10nMock->expects($this->any())
->method('t')
- ->willReturnCallback(function($message) {
+ ->willReturnCallback(function ($message) {
return $message;
});
diff --git a/apps/encryption/tests/Controller/StatusControllerTest.php b/apps/encryption/tests/Controller/StatusControllerTest.php
index 1f5f02a2920..fe2616f9c54 100644
--- a/apps/encryption/tests/Controller/StatusControllerTest.php
+++ b/apps/encryption/tests/Controller/StatusControllerTest.php
@@ -63,7 +63,7 @@ class StatusControllerTest extends TestCase {
->disableOriginalConstructor()->getMock();
$this->l10nMock->expects($this->any())
->method('t')
- ->willReturnCallback(function($message) {
+ ->willReturnCallback(function ($message) {
return $message;
});
$this->encryptionManagerMock = $this->createMock(IManager::class);
diff --git a/apps/encryption/tests/Crypto/CryptTest.php b/apps/encryption/tests/Crypto/CryptTest.php
index d222d94c16c..dd892616d0f 100644
--- a/apps/encryption/tests/Crypto/CryptTest.php
+++ b/apps/encryption/tests/Crypto/CryptTest.php
@@ -294,7 +294,7 @@ class CryptTest extends TestCase {
*
* @return array
*/
- public function dataProviderRemovePadding() {
+ public function dataProviderRemovePadding() {
return [
['dataxx', 'data'],
['data', false]
diff --git a/apps/encryption/tests/Crypto/EncryptAllTest.php b/apps/encryption/tests/Crypto/EncryptAllTest.php
index 7f67f701b50..f5fd3d2287f 100644
--- a/apps/encryption/tests/Crypto/EncryptAllTest.php
+++ b/apps/encryption/tests/Crypto/EncryptAllTest.php
@@ -322,7 +322,7 @@ class EncryptAllTest extends TestCase {
$this->view->expects($this->any())->method('is_dir')
->willReturnCallback(
- function($path) {
+ function ($path) {
if ($path === '/user1/files/foo') {
return true;
}
diff --git a/apps/encryption/tests/Crypto/EncryptionTest.php b/apps/encryption/tests/Crypto/EncryptionTest.php
index 26e32c3a182..1e4cfad5e30 100644
--- a/apps/encryption/tests/Crypto/EncryptionTest.php
+++ b/apps/encryption/tests/Crypto/EncryptionTest.php
@@ -323,7 +323,7 @@ class EncryptionTest extends TestCase {
$this->keyManagerMock->expects($this->any())
->method('addSystemKeys')
- ->willReturnCallback(function($accessList, $publicKeys) {
+ ->willReturnCallback(function ($accessList, $publicKeys) {
return $publicKeys;
});
@@ -350,7 +350,7 @@ class EncryptionTest extends TestCase {
$this->keyManagerMock->expects($this->never())->method('getPublicKey');
$this->keyManagerMock->expects($this->never())->method('addSystemKeys');
$this->keyManagerMock->expects($this->once())->method('setVersion')
- ->willReturnCallback(function($path, $version, $view) {
+ ->willReturnCallback(function ($path, $version, $view) {
$this->assertSame('path', $path);
$this->assertSame(2, $version);
$this->assertTrue($view instanceof \OC\Files\View);
@@ -368,20 +368,20 @@ class EncryptionTest extends TestCase {
$this->keyManagerMock->expects($this->any())
->method('getPublicKey')->willReturnCallback(
- function($user) {
+ function ($user) {
throw new PublicKeyMissingException($user);
}
);
$this->keyManagerMock->expects($this->any())
->method('addSystemKeys')
- ->willReturnCallback(function($accessList, $publicKeys) {
+ ->willReturnCallback(function ($accessList, $publicKeys) {
return $publicKeys;
});
$this->cryptMock->expects($this->once())->method('multiKeyEncrypt')
->willReturnCallback(
- function($fileKey, $publicKeys) {
+ function ($fileKey, $publicKeys) {
$this->assertEmpty($publicKeys);
$this->assertSame('fileKey', $fileKey);
}
diff --git a/apps/encryption/tests/KeyManagerTest.php b/apps/encryption/tests/KeyManagerTest.php
index 69f238d5ef7..2e2fce2b349 100644
--- a/apps/encryption/tests/KeyManagerTest.php
+++ b/apps/encryption/tests/KeyManagerTest.php
@@ -242,7 +242,7 @@ class KeyManagerTest extends TestCase {
$this->keyStorageMock->expects($this->exactly(2))
->method('getUserKey')
- ->willReturnCallback(function ($uid, $keyID, $encryptionModuleId){
+ ->willReturnCallback(function ($uid, $keyID, $encryptionModuleId) {
if ($keyID === 'publicKey') {
return '';
}
@@ -473,13 +473,13 @@ class KeyManagerTest extends TestCase {
$this->keyStorageMock->expects($this->any())
->method('getSystemUserKey')
- ->willReturnCallback(function($keyId, $encryptionModuleId) {
+ ->willReturnCallback(function ($keyId, $encryptionModuleId) {
return $keyId;
});
$this->utilMock->expects($this->any())
->method('isRecoveryEnabledForUser')
- ->willReturnCallback(function($uid) {
+ ->willReturnCallback(function ($uid) {
if ($uid === 'user1') {
return true;
}