ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
Sabre\CalDAV\Schedule\PluginPropertiesWithSharedCalendarTest Class Reference
+ Inheritance diagram for Sabre\CalDAV\Schedule\PluginPropertiesWithSharedCalendarTest:
+ Collaboration diagram for Sabre\CalDAV\Schedule\PluginPropertiesWithSharedCalendarTest:

Public Member Functions

 setUp ()
 
 testPrincipalProperties ()
 
- Public Member Functions inherited from Sabre\DAVServerTest
 setUp ()
 
 initializeEverything ()
 
 request ($request, $expectedStatus=null)
 Makes a request, and returns a response object. More...
 
 autoLogin ($userName)
 This function takes a username and sets the server in a state where this user is logged in, and no longer requires an authentication check. More...
 
 setUpTree ()
 Override this to provide your own Tree for your test-case. More...
 
 setUpBackends ()
 
 assertHttpStatus ($expectedStatus, HTTP\Request $req)
 

Protected Attributes

 $setupCalDAV = true
 
 $setupCalDAVScheduling = true
 
 $setupCalDAVSharing = true
 
- Protected Attributes inherited from Sabre\DAVServerTest
 $setupCalDAV = false
 
 $setupCardDAV = false
 
 $setupACL = false
 
 $setupCalDAVSharing = false
 
 $setupCalDAVScheduling = false
 
 $setupCalDAVSubscriptions = false
 
 $setupCalDAVICSExport = false
 
 $setupLocks = false
 
 $setupFiles = false
 
 $setupSharing = false
 
 $setupPropertyStorage = false
 
 $caldavCalendars = []
 An array with calendars. More...
 
 $caldavCalendarObjects = []
 
 $carddavAddressBooks = []
 
 $carddavCards = []
 
 $server
 
 $tree = []
 
 $caldavBackend
 
 $carddavBackend
 
 $principalBackend
 
 $locksBackend
 
 $propertyStorageBackend
 
 $caldavPlugin
 
 $carddavPlugin
 
 $aclPlugin
 
 $caldavSharingPlugin
 
 $caldavSchedulePlugin
 
 $authPlugin
 
 $locksPlugin
 
 $sharingPlugin
 
 $propertyStoragePlugin
 
 $autoLogin = null
 If this string is set, we will automatically log in the user with this name. More...
 

Detailed Description

Definition at line 7 of file PluginPropertiesWithSharedCalendarTest.php.

Member Function Documentation

◆ setUp()

Sabre\CalDAV\Schedule\PluginPropertiesWithSharedCalendarTest::setUp ( )

Reimplemented from Sabre\DAVServerTest.

Definition at line 13 of file PluginPropertiesWithSharedCalendarTest.php.

13 {
14
15 parent::setUp();
16 $this->caldavBackend->createCalendar(
17 'principals/user1',
18 'shared',
19 [
20 'share-access' => DAV\Sharing\Plugin::ACCESS_READWRITE
21 ]
22 );
23 $this->caldavBackend->createCalendar(
24 'principals/user1',
25 'default',
26 [
27
28 ]
29 );
30
31 }

◆ testPrincipalProperties()

Sabre\CalDAV\Schedule\PluginPropertiesWithSharedCalendarTest::testPrincipalProperties ( )

Definition at line 33 of file PluginPropertiesWithSharedCalendarTest.php.

33 {
34
35 $props = $this->server->getPropertiesForPath('/principals/user1', [
36 '{urn:ietf:params:xml:ns:caldav}schedule-inbox-URL',
37 '{urn:ietf:params:xml:ns:caldav}schedule-outbox-URL',
38 '{urn:ietf:params:xml:ns:caldav}calendar-user-address-set',
39 '{urn:ietf:params:xml:ns:caldav}calendar-user-type',
40 '{urn:ietf:params:xml:ns:caldav}schedule-default-calendar-URL',
41 ]);
42
43 $this->assertArrayHasKey(0, $props);
44 $this->assertArrayHasKey(200, $props[0]);
45
46 $this->assertArrayHasKey('{urn:ietf:params:xml:ns:caldav}schedule-outbox-URL', $props[0][200]);
47 $prop = $props[0][200]['{urn:ietf:params:xml:ns:caldav}schedule-outbox-URL'];
48 $this->assertTrue($prop instanceof DAV\Xml\Property\Href);
49 $this->assertEquals('calendars/user1/outbox/', $prop->getHref());
50
51 $this->assertArrayHasKey('{urn:ietf:params:xml:ns:caldav}schedule-inbox-URL', $props[0][200]);
52 $prop = $props[0][200]['{urn:ietf:params:xml:ns:caldav}schedule-inbox-URL'];
53 $this->assertTrue($prop instanceof DAV\Xml\Property\Href);
54 $this->assertEquals('calendars/user1/inbox/', $prop->getHref());
55
56 $this->assertArrayHasKey('{urn:ietf:params:xml:ns:caldav}calendar-user-address-set', $props[0][200]);
57 $prop = $props[0][200]['{urn:ietf:params:xml:ns:caldav}calendar-user-address-set'];
58 $this->assertTrue($prop instanceof DAV\Xml\Property\Href);
59 $this->assertEquals(['mailto:user1.sabredav@sabredav.org', '/principals/user1/'], $prop->getHrefs());
60
61 $this->assertArrayHasKey('{urn:ietf:params:xml:ns:caldav}calendar-user-type', $props[0][200]);
62 $prop = $props[0][200]['{urn:ietf:params:xml:ns:caldav}calendar-user-type'];
63 $this->assertEquals('INDIVIDUAL', $prop);
64
65 $this->assertArrayHasKey('{urn:ietf:params:xml:ns:caldav}schedule-default-calendar-URL', $props[0][200]);
66 $prop = $props[0][200]['{urn:ietf:params:xml:ns:caldav}schedule-default-calendar-URL'];
67 $this->assertEquals('calendars/user1/default/', $prop->getHref());
68
69 }

Field Documentation

◆ $setupCalDAV

Sabre\CalDAV\Schedule\PluginPropertiesWithSharedCalendarTest::$setupCalDAV = true
protected

Definition at line 9 of file PluginPropertiesWithSharedCalendarTest.php.

◆ $setupCalDAVScheduling

Sabre\CalDAV\Schedule\PluginPropertiesWithSharedCalendarTest::$setupCalDAVScheduling = true
protected

Definition at line 10 of file PluginPropertiesWithSharedCalendarTest.php.

◆ $setupCalDAVSharing

Sabre\CalDAV\Schedule\PluginPropertiesWithSharedCalendarTest::$setupCalDAVSharing = true
protected

Definition at line 11 of file PluginPropertiesWithSharedCalendarTest.php.


The documentation for this class was generated from the following file: