diff options
author | Côme Chilliet <come.chilliet@nextcloud.com> | 2025-03-24 11:12:51 +0100 |
---|---|---|
committer | Grigorii K. Shartsev <me@shgk.me> | 2025-04-23 18:52:53 +0200 |
commit | 6355a54ca670a901045298b8581faae35379184e (patch) | |
tree | 2441c0d1cc58c00936ff6a35846406133dda73fb | |
parent | 3c1c7b87186fb16a12c6607c8931ec11a304aa67 (diff) | |
download | nextcloud-server-backport/51602/stable28.tar.gz nextcloud-server-backport/51602/stable28.zip |
chore(tests): Adapt DefaultShareProviderTest to new constructor parameterbackport/51602/stable28
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
-rw-r--r-- | tests/lib/Share20/DefaultShareProviderTest.php | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/lib/Share20/DefaultShareProviderTest.php b/tests/lib/Share20/DefaultShareProviderTest.php index 3f2fdd236c1..b79409d7444 100644 --- a/tests/lib/Share20/DefaultShareProviderTest.php +++ b/tests/lib/Share20/DefaultShareProviderTest.php @@ -30,6 +30,7 @@ use OCP\Defaults; use OCP\Files\File; use OCP\Files\Folder; use OCP\Files\IRootFolder; +use OCP\IConfig; use OCP\IDBConnection; use OCP\IGroup; use OCP\IGroupManager; @@ -83,6 +84,9 @@ class DefaultShareProviderTest extends \Test\TestCase { /** @var ITimeFactory|MockObject */ protected $timeFactory; + /** @var IConfig&MockObject */ + protected $config; + /** @var IShareManager&MockObject */ protected $shareManager; @@ -98,6 +102,7 @@ class DefaultShareProviderTest extends \Test\TestCase { $this->urlGenerator = $this->createMock(IURLGenerator::class); $this->timeFactory = $this->createMock(ITimeFactory::class); $this->shareManager = $this->createMock(IShareManager::class); + $this->config = $this->createMock(IConfig::class); $this->userManager->expects($this->any())->method('userExists')->willReturn(true); $this->timeFactory->expects($this->any())->method('now')->willReturn(new \DateTimeImmutable("2023-05-04 00:00 Europe/Berlin")); @@ -116,6 +121,7 @@ class DefaultShareProviderTest extends \Test\TestCase { $this->urlGenerator, $this->timeFactory, $this->shareManager, + $this->config, ); } @@ -478,6 +484,7 @@ class DefaultShareProviderTest extends \Test\TestCase { $this->urlGenerator, $this->timeFactory, $this->shareManager, + $this->config, ]) ->setMethods(['getShareById']) ->getMock(); @@ -574,6 +581,7 @@ class DefaultShareProviderTest extends \Test\TestCase { $this->urlGenerator, $this->timeFactory, $this->shareManager, + $this->config, ]) ->setMethods(['getShareById']) ->getMock(); @@ -2569,6 +2577,7 @@ class DefaultShareProviderTest extends \Test\TestCase { $this->urlGenerator, $this->timeFactory, $this->shareManager, + $this->config, ); $password = md5(time()); @@ -2668,6 +2677,7 @@ class DefaultShareProviderTest extends \Test\TestCase { $this->urlGenerator, $this->timeFactory, $this->shareManager, + $this->config, ); $u1 = $userManager->createUser('testShare1', 'test'); @@ -2765,6 +2775,7 @@ class DefaultShareProviderTest extends \Test\TestCase { $this->urlGenerator, $this->timeFactory, $this->shareManager, + $this->config, ); $u1 = $userManager->createUser('testShare1', 'test'); |