diff options
author | Georg Ehrke <developer@georgehrke.com> | 2020-08-11 09:24:08 +0200 |
---|---|---|
committer | Georg Ehrke <developer@georgehrke.com> | 2020-08-18 13:18:00 +0200 |
commit | 14755d85d657ab9bac4458b891c6f43b110b1cf2 (patch) | |
tree | 4eea0f88ac0902dafc25574f9eb1b553c1987797 /apps/dav/tests/unit | |
parent | f6daf17fa773bd4b9c9aae070e39dfbefe8de935 (diff) | |
download | nextcloud-server-14755d85d657ab9bac4458b891c6f43b110b1cf2.tar.gz nextcloud-server-14755d85d657ab9bac4458b891c6f43b110b1cf2.zip |
Add ability to limit sharing to owner
Signed-off-by: Georg Ehrke <developer@georgehrke.com>
Diffstat (limited to 'apps/dav/tests/unit')
-rw-r--r-- | apps/dav/tests/unit/CardDAV/Sharing/PluginTest.php | 4 | ||||
-rw-r--r-- | apps/dav/tests/unit/DAV/Sharing/PluginTest.php | 4 |
2 files changed, 6 insertions, 2 deletions
diff --git a/apps/dav/tests/unit/CardDAV/Sharing/PluginTest.php b/apps/dav/tests/unit/CardDAV/Sharing/PluginTest.php index 146ead4ed3f..472826ac2f7 100644 --- a/apps/dav/tests/unit/CardDAV/Sharing/PluginTest.php +++ b/apps/dav/tests/unit/CardDAV/Sharing/PluginTest.php @@ -30,6 +30,7 @@ namespace OCA\DAV\Tests\unit\CardDAV\Sharing; use OCA\DAV\Connector\Sabre\Auth; use OCA\DAV\DAV\Sharing\IShareable; use OCA\DAV\DAV\Sharing\Plugin; +use OCP\IConfig; use OCP\IRequest; use Sabre\DAV\Server; use Sabre\DAV\SimpleCollection; @@ -55,7 +56,8 @@ class PluginTest extends TestCase { /** @var IRequest $request */ $request = $this->getMockBuilder(IRequest::class)->disableOriginalConstructor()->getMock(); - $this->plugin = new Plugin($authBackend, $request); + $config = $this->createMock(IConfig::class); + $this->plugin = new Plugin($authBackend, $request, $config); $root = new SimpleCollection('root'); $this->server = new \Sabre\DAV\Server($root); diff --git a/apps/dav/tests/unit/DAV/Sharing/PluginTest.php b/apps/dav/tests/unit/DAV/Sharing/PluginTest.php index 038e0f9e7bf..0b01f46ffec 100644 --- a/apps/dav/tests/unit/DAV/Sharing/PluginTest.php +++ b/apps/dav/tests/unit/DAV/Sharing/PluginTest.php @@ -30,6 +30,7 @@ namespace OCA\DAV\Tests\unit\DAV\Sharing; use OCA\DAV\Connector\Sabre\Auth; use OCA\DAV\DAV\Sharing\IShareable; use OCA\DAV\DAV\Sharing\Plugin; +use OCP\IConfig; use OCP\IRequest; use Sabre\DAV\Server; use Sabre\DAV\SimpleCollection; @@ -55,7 +56,8 @@ class PluginTest extends TestCase { /** @var IRequest $request */ $request = $this->getMockBuilder(IRequest::class)->disableOriginalConstructor()->getMock(); - $this->plugin = new Plugin($authBackend, $request); + $config = $this->createMock(IConfig::class); + $this->plugin = new Plugin($authBackend, $request, $config); $root = new SimpleCollection('root'); $this->server = new \Sabre\DAV\Server($root); |