aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--apps/files/tests/Controller/ApiControllerTest.php17
1 files changed, 16 insertions, 1 deletions
diff --git a/apps/files/tests/Controller/ApiControllerTest.php b/apps/files/tests/Controller/ApiControllerTest.php
index 844fabc93a3..f79a5c7bb64 100644
--- a/apps/files/tests/Controller/ApiControllerTest.php
+++ b/apps/files/tests/Controller/ApiControllerTest.php
@@ -14,15 +14,18 @@ use OCP\AppFramework\Http;
use OCP\AppFramework\Http\DataResponse;
use OCP\Files\File;
use OCP\Files\Folder;
+use OCP\Files\IRootFolder;
use OCP\Files\NotFoundException;
use OCP\Files\SimpleFS\ISimpleFile;
use OCP\Files\StorageNotAvailableException;
use OCP\IConfig;
+use OCP\IL10N;
use OCP\IPreview;
use OCP\IRequest;
use OCP\IUser;
use OCP\IUserSession;
use OCP\Share\IManager;
+use Psr\Log\LoggerInterface;
use Test\TestCase;
/**
@@ -53,6 +56,12 @@ class ApiControllerTest extends TestCase {
private $userConfig;
/** @var ViewConfig|\PHPUnit\Framework\MockObject\MockObject */
private $viewConfig;
+ /** @var IL10N|\PHPUnit\Framework\MockObject\MockObject */
+ private $l10n;
+ /** @var IRootFolder|\PHPUnit\Framework\MockObject\MockObject */
+ private $rootFolder;
+ /** @var LoggerInterface|\PHPUnit\Framework\MockObject\MockObject */
+ private $logger;
protected function setUp(): void {
parent::setUp();
@@ -83,6 +92,9 @@ class ApiControllerTest extends TestCase {
->getMock();
$this->userConfig = $this->createMock(UserConfig::class);
$this->viewConfig = $this->createMock(ViewConfig::class);
+ $this->l10n = $this->createMock(IL10N::class);
+ $this->rootFolder = $this->createMock(IRootFolder::class);
+ $this->logger = $this->createMock(LoggerInterface::class);
$this->apiController = new ApiController(
$this->appName,
@@ -94,7 +106,10 @@ class ApiControllerTest extends TestCase {
$this->config,
$this->userFolder,
$this->userConfig,
- $this->viewConfig
+ $this->viewConfig,
+ $this->l10n,
+ $this->rootFolder,
+ $this->logger,
);
}