From da9a5415a1b3a55fd8335604ccf3bbd4b2fcb2e3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?John=20Molakvo=C3=A6=20=28skjnldsv=29?= Date: Fri, 4 Jun 2021 08:11:49 +0200 Subject: Properly check for circles version MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: John Molakvoæ (skjnldsv) --- tests/unit/Controller/PageControllerTest.php | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'tests') diff --git a/tests/unit/Controller/PageControllerTest.php b/tests/unit/Controller/PageControllerTest.php index 1b3625e2..a60bfcc0 100644 --- a/tests/unit/Controller/PageControllerTest.php +++ b/tests/unit/Controller/PageControllerTest.php @@ -25,9 +25,10 @@ namespace OCA\Contacts\Controller; use ChristophWurst\Nextcloud\Testing\TestCase; +use OC\App\CompareVersion; use OCA\Contacts\Service\SocialApiService; -use OCP\AppFramework\Http\TemplateResponse; use OCP\App\IAppManager; +use OCP\AppFramework\Http\TemplateResponse; use OCP\IConfig; use OCP\IInitialStateService; use OCP\IRequest; @@ -60,6 +61,9 @@ class PageControllerTest extends TestCase { /** @var IAppManager|MockObject*/ private $appManager; + /** @var CompareVersion|MockObject*/ + private $compareVersion; + protected function setUp(): void { parent::setUp(); @@ -70,6 +74,7 @@ class PageControllerTest extends TestCase { $this->userSession = $this->createMock(IUserSession::class); $this->socialApi = $this->createMock(SocialApiService::class); $this->appManager = $this->createMock(IAppManager::class); + $this->compareVersion = $this->createMock(CompareVersion::class); $this->controller = new PageController( $this->request, @@ -78,7 +83,8 @@ class PageControllerTest extends TestCase { $this->languageFactory, $this->userSession, $this->socialApi, - $this->appManager + $this->appManager, + $this->compareVersion ); } -- cgit v1.2.3