diff options
author | Thomas Citharel <tcit@tcit.fr> | 2017-09-20 17:33:51 +0200 |
---|---|---|
committer | Roeland Jago Douma <roeland@famdouma.nl> | 2017-12-11 16:28:40 +0100 |
commit | 4c32de22bbe8b21477e5d7c5043768ad8ad77d0c (patch) | |
tree | 83dc4eb5a61ca3cb25c805be85b8ebb330399808 /apps/dav/tests | |
parent | 80b27fdb93ac0c170d0b5e214f67a2eff6c366ad (diff) | |
download | nextcloud-server-4c32de22bbe8b21477e5d7c5043768ad8ad77d0c.tar.gz nextcloud-server-4c32de22bbe8b21477e5d7c5043768ad8ad77d0c.zip |
Create activities for (un)publishing calendar events
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
Diffstat (limited to 'apps/dav/tests')
-rw-r--r-- | apps/dav/tests/unit/CalDAV/Activity/BackendTest.php | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/apps/dav/tests/unit/CalDAV/Activity/BackendTest.php b/apps/dav/tests/unit/CalDAV/Activity/BackendTest.php index 16b2b8a616e..cec734b9a8f 100644 --- a/apps/dav/tests/unit/CalDAV/Activity/BackendTest.php +++ b/apps/dav/tests/unit/CalDAV/Activity/BackendTest.php @@ -79,6 +79,7 @@ class BackendTest extends TestCase { ['onCalendarAdd', [['data']], Calendar::SUBJECT_ADD, [['data'], [], []]], ['onCalendarUpdate', [['data'], ['shares'], ['changed-properties']], Calendar::SUBJECT_UPDATE, [['data'], ['shares'], ['changed-properties']]], ['onCalendarDelete', [['data'], ['shares']], Calendar::SUBJECT_DELETE, [['data'], ['shares'], []]], + ['onCalendarPublication', [['data'], true], Calendar::SUBJECT_PUBLISH, [['data'], [], []]], ]; } @@ -163,6 +164,22 @@ class BackendTest extends TestCase { 'uri' => 'this-uri', '{DAV:}displayname' => 'Name of calendar', ], ['shares'], [], 'test2', 'test2', ['user1'], ['user1', 'admin']], + + // Publish calendar + [Calendar::SUBJECT_PUBLISH, [], [], [], '', '', null, []], + [Calendar::SUBJECT_PUBLISH, [ + 'principaluri' => 'principal/user/admin', + 'id' => 42, + '{DAV:}displayname' => 'Name of calendar', + ], ['shares'], [], '', 'admin', [], ['admin']], + + // Unpublish calendar + [Calendar::SUBJECT_UNPUBLISH, [], [], [], '', '', null, []], + [Calendar::SUBJECT_UNPUBLISH, [ + 'principaluri' => 'principal/user/admin', + 'id' => 42, + '{DAV:}displayname' => 'Name of calendar', + ], ['shares'], [], '', 'admin', [], ['admin']], ]; } |