]> git.mxchange.org Git - friendica-addons.git/blob - dav/SabreDAV/tests/Sabre/CalDAV/Notifications/CollectionTest.php
1d396d6daac5a4d2b1ad438fd54734d772c51429
[friendica-addons.git] / dav / SabreDAV / tests / Sabre / CalDAV / Notifications / CollectionTest.php
1 <?php
2
3 class Sabre_CalDAV_Notifications_CollectionTest extends \PHPUnit_Framework_TestCase {
4
5     function testGetChildren() {
6
7         $principalUri = 'principals/user1';
8
9         $systemStatus = new Sabre_CalDAV_Notifications_Notification_SystemStatus(1);
10
11         $caldavBackend = new Sabre_CalDAV_Backend_Mock(array(),array(), array(
12             'principals/user1' => array(
13                 $systemStatus
14             )
15         )); 
16
17
18         $col = new Sabre_CalDAV_Notifications_Collection($caldavBackend, $principalUri);
19         $this->assertEquals('notifications', $col->getName());
20
21         $this->assertEquals(array(
22             new Sabre_CalDAV_Notifications_Node($caldavBackend, $systemStatus)
23         ), $col->getChildren()); 
24
25     }
26
27 }