Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/spreed.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorJoas Schilling <213943+nickvergessen@users.noreply.github.com>2020-05-18 16:31:15 +0300
committerGitHub <noreply@github.com>2020-05-18 16:31:15 +0300
commit3307c6a8d64f652d8bb5bedf6107c3d398a0cb68 (patch)
treefe50b9354486ab62d4b37ce9e25dfae5e044b7a0 /tests
parent2543bc65137d5239b7a222fb3e97200fdf19add5 (diff)
parentd4ec6c04a0fa6f00480e94d0cfbab8d2c670cebf (diff)
Merge pull request #3565 from nextcloud/bugfix/noid/hpb-multi-setup-protection
Don't allow multiple HPB without clustering and add a cache warning
Diffstat (limited to 'tests')
-rw-r--r--tests/php/Settings/Admin/AdminSettingsTest.php17
1 files changed, 9 insertions, 8 deletions
diff --git a/tests/php/Settings/Admin/AdminSettingsTest.php b/tests/php/Settings/Admin/AdminSettingsTest.php
index f9122461e..ee01a019d 100644
--- a/tests/php/Settings/Admin/AdminSettingsTest.php
+++ b/tests/php/Settings/Admin/AdminSettingsTest.php
@@ -26,6 +26,7 @@ namespace OCA\Talk\Tests\php\Settings\Admin;
use OCA\Talk\Config;
use OCA\Talk\Service\CommandService;
use OCA\Talk\Settings\Admin\AdminSettings;
+use OCP\ICacheFactory;
use OCP\IConfig;
use OCP\IInitialStateService;
use PHPUnit\Framework\MockObject\MockObject;
@@ -40,7 +41,9 @@ class AdminSettingsTest extends \Test\TestCase {
protected $commandService;
/** @var IInitialStateService|MockObject */
protected $initialState;
- /** @var StunServer */
+ /** @var ICacheFactory|MockObject */
+ protected $cacheFactory;
+ /** @var AdminSettings */
protected $admin;
public function setUp(): void {
@@ -50,13 +53,9 @@ class AdminSettingsTest extends \Test\TestCase {
$this->serverConfig = $this->createMock(IConfig::class);
$this->commandService = $this->createMock(CommandService::class);
$this->initialState = $this->createMock(IInitialStateService::class);
+ $this->cacheFactory = $this->createMock(ICacheFactory::class);
- $this->admin = new AdminSettings(
- $this->talkConfig,
- $this->serverConfig,
- $this->commandService,
- $this->initialState
- );
+ $this->admin = $this->getAdminSettings();
}
/**
@@ -69,7 +68,8 @@ class AdminSettingsTest extends \Test\TestCase {
$this->talkConfig,
$this->serverConfig,
$this->commandService,
- $this->initialState
+ $this->initialState,
+ $this->cacheFactory
);
}
@@ -79,6 +79,7 @@ class AdminSettingsTest extends \Test\TestCase {
$this->serverConfig,
$this->commandService,
$this->initialState,
+ $this->cacheFactory,
])
->onlyMethods($methods)
->getMock();