Skip to content

Commit

Permalink
test: Update tests
Browse files Browse the repository at this point in the history
Signed-off-by: Christopher Ng <[email protected]>
  • Loading branch information
Pytal committed Jan 9, 2025
1 parent 6bcbc5a commit 3801197
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions tests/lib/Share20/ManagerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
use OCP\Files\NotFoundException;
use OCP\Files\Storage\IStorage;
use OCP\HintException;
use OCP\IAppConfig;
use OCP\IConfig;
use OCP\IDateTimeZone;
use OCP\IGroup;
Expand Down Expand Up @@ -109,6 +110,8 @@ class ManagerTest extends \Test\TestCase {
private DateTimeZone $timezone;
/** @var IDateTimeZone|MockObject */
protected $dateTimeZone;
/** @var IAppConfig|MockObject */
protected $appConfig;

protected function setUp(): void {
$this->logger = $this->createMock(LoggerInterface::class);
Expand All @@ -131,6 +134,8 @@ protected function setUp(): void {
$this->timezone = new \DateTimeZone('Pacific/Auckland');
$this->dateTimeZone->method('getTimeZone')->willReturnCallback(fn () => $this->timezone);

$this->appConfig = $this->createMock(IAppConfig::class);

$this->l10nFactory = $this->createMock(IFactory::class);
$this->l = $this->createMock(IL10N::class);
$this->l->method('t')
Expand Down Expand Up @@ -172,6 +177,7 @@ private function createManager(IProviderFactory $factory): Manager {
$this->knownUserService,
$this->shareDisabledChecker,
$this->dateTimeZone,
$this->appConfig,
);
}

Expand Down Expand Up @@ -199,6 +205,7 @@ private function createManagerMock() {
$this->knownUserService,
$this->shareDisabledChecker,
$this->dateTimeZone,
$this->appConfig,
]);
}

Expand Down

0 comments on commit 3801197

Please sign in to comment.