From 4c48d6bf18c0394fc617a73c9bbc2872d7d2421f Mon Sep 17 00:00:00 2001 From: "Jan C. Borchardt" Date: Thu, 6 Aug 2020 22:55:30 +0200 Subject: Add 'Reasons to use Nextcloud in your organization' call to action in settings Signed-off-by: Jan C. Borchardt --- apps/settings/tests/Controller/AdminSettingsControllerTest.php | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'apps/settings/tests/Controller/AdminSettingsControllerTest.php') 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'); -- cgit v1.2.3