summaryrefslogtreecommitdiffstats
path: root/apps/settings/tests
diff options
context:
space:
mode:
authorRoeland Jago Douma <rullzer@users.noreply.github.com>2020-09-07 08:49:05 +0200
committerGitHub <noreply@github.com>2020-09-07 08:49:05 +0200
commit16e1d1cb12229270d61d89dfda93399d056d456c (patch)
treeee06cae75f267622981053aa88b4d66dac5de605 /apps/settings/tests
parent54438c9d2689748f41262e73fb9b1ba8e4b7969e (diff)
parent4c48d6bf18c0394fc617a73c9bbc2872d7d2421f (diff)
downloadnextcloud-server-16e1d1cb12229270d61d89dfda93399d056d456c.tar.gz
nextcloud-server-16e1d1cb12229270d61d89dfda93399d056d456c.zip
Merge pull request #22136 from nextcloud/design/reasons-to-use-nextcloud
Add 'Reasons to use Nextcloud in your organization' call to action in settings
Diffstat (limited to 'apps/settings/tests')
-rw-r--r--apps/settings/tests/Controller/AdminSettingsControllerTest.php6
1 files changed, 2 insertions, 4 deletions
diff --git a/apps/settings/tests/Controller/AdminSettingsControllerTest.php b/apps/settings/tests/Controller/AdminSettingsControllerTest.php
index 137540c52d4..21bd29de355 100644
--- a/apps/settings/tests/Controller/AdminSettingsControllerTest.php
+++ b/apps/settings/tests/Controller/AdminSettingsControllerTest.php
@@ -37,7 +37,6 @@ use OCP\IRequest;
use OCP\IUser;
use OCP\IUserSession;
use OCP\Settings\IManager;
-use OCP\Support\Subscription\IRegistry;
use PHPUnit\Framework\MockObject\MockObject;
use Test\TestCase;
@@ -87,7 +86,7 @@ class AdminSettingsControllerTest extends TestCase {
$this->subAdmin
);
- $user = \OC::$server->getUserManager()->createUser($this->adminUid, 'olo');
+ $user = \OC::$server->getUserManager()->createUser($this->adminUid, 'mylongrandompassword');
\OC_User::setUserId($user->getUID());
\OC::$server->getGroupManager()->createGroup('admin')->addUser($user);
}
@@ -100,7 +99,6 @@ class AdminSettingsControllerTest extends TestCase {
public function testIndex() {
$user = $this->createMock(IUser::class);
- $registry = $this->createMock(IRegistry::class);
$this->userSession
->method('getUser')
->willReturn($user);
@@ -125,7 +123,7 @@ class AdminSettingsControllerTest extends TestCase {
->expects($this->once())
->method('getAdminSettings')
->with('test')
- ->willReturn([5 => new ServerDevNotice($registry)]);
+ ->willReturn([5 => $this->createMock(ServerDevNotice::class)]);
$idx = $this->adminSettingsController->index('test');