summaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
Diffstat (limited to 'apps')
-rw-r--r--apps/dav/lib/CalDAV/CalDavBackend.php7
-rw-r--r--apps/dav/tests/unit/CalDAV/PublicCalendarRootTest.php18
2 files changed, 18 insertions, 7 deletions
diff --git a/apps/dav/lib/CalDAV/CalDavBackend.php b/apps/dav/lib/CalDAV/CalDavBackend.php
index 5f903406168..0cdfcd69571 100644
--- a/apps/dav/lib/CalDAV/CalDavBackend.php
+++ b/apps/dav/lib/CalDAV/CalDavBackend.php
@@ -130,9 +130,12 @@ class CalDavBackend extends AbstractBackend implements SyncSupport, Subscription
* @param IDBConnection $db
* @param Principal $principalBackend
* @param IUserManager $userManager
- * @param IConfig $config
+ * @param IConfig $config
*/
- public function __construct(IDBConnection $db, Principal $principalBackend, IUserManager $userManager, IConfig $config) {
+ public function __construct(IDBConnection $db,
+ Principal $principalBackend,
+ IUserManager $userManager,
+ IConfig $config) {
$this->db = $db;
$this->principalBackend = $principalBackend;
$this->userManager = $userManager;
diff --git a/apps/dav/tests/unit/CalDAV/PublicCalendarRootTest.php b/apps/dav/tests/unit/CalDAV/PublicCalendarRootTest.php
index 9ce558ad34b..85aad24d368 100644
--- a/apps/dav/tests/unit/CalDAV/PublicCalendarRootTest.php
+++ b/apps/dav/tests/unit/CalDAV/PublicCalendarRootTest.php
@@ -3,10 +3,12 @@
namespace OCA\DAV\Tests\unit\CalDAV;
use OCA\DAV\CalDAV\Calendar;
+use OCA\DAV\Connector\Sabre\Principal;
use OCP\IL10N;
use OCP\IConfig;
use OCA\DAV\CalDAV\CalDavBackend;
use OCA\DAV\CalDAV\PublicCalendarRoot;
+use OCP\IUserManager;
use Test\TestCase;
use Sabre\Uri;
@@ -29,12 +31,13 @@ class PublicCalendarRootTest extends TestCase {
/** @var IL10N */
private $l10n;
-
+ /** @var IUserManager */
+ private $userManager;
+ /** @var Principal */
+ private $principal;
/** var IConfig */
protected $config;
- private $principal;
-
public function setUp() {
parent::setUp();
@@ -43,8 +46,14 @@ class PublicCalendarRootTest extends TestCase {
->disableOriginalConstructor()
->getMock();
$this->config = \OC::$server->getConfig();
+ $this->userManager = $this->getMockBuilder('\OCP\IUserManager')->getMock();
- $this->backend = new CalDavBackend($db, $this->principal, $this->config);
+ $this->backend = new CalDavBackend(
+ $db,
+ $this->principal,
+ $this->userManager,
+ $this->config
+ );
$this->publicCalendarRoot = new PublicCalendarRoot($this->backend);
@@ -99,5 +108,4 @@ class PublicCalendarRootTest extends TestCase {
return $calendar;
}
-
}