[Pkg-owncloud-commits] [php-sabredav] 35/275: Added a first unittest for iTip delivery.

David Prévot taffit at moszumanska.debian.org
Thu Sep 25 14:55:48 UTC 2014


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch master
in repository php-sabredav.

commit 96ace76417dd3876845b726aad4d1b572b6fcf2d
Author: Evert Pot <evert at rooftopsolutions.nl>
Date:   Mon Jan 13 23:14:52 2014 -0500

    Added a first unittest for iTip delivery.
---
 .../Sabre/CalDAV/Schedule/DeliverNewEventTest.php  | 58 ++++++++++++++++++++++
 1 file changed, 58 insertions(+)

diff --git a/tests/Sabre/CalDAV/Schedule/DeliverNewEventTest.php b/tests/Sabre/CalDAV/Schedule/DeliverNewEventTest.php
new file mode 100644
index 0000000..9ca0ff9
--- /dev/null
+++ b/tests/Sabre/CalDAV/Schedule/DeliverNewEventTest.php
@@ -0,0 +1,58 @@
+<?php
+
+namespace Sabre\CalDAV\Schedule;
+
+use
+    Sabre\HTTP\Request;
+
+class DeliverNewEventTest extends \Sabre\DAVServerTest {
+
+    public $setupCalDAV = true;
+    public $setupCalDAVScheduling = true;
+
+    function setUp() {
+
+        parent::setUp();
+        $this->caldavBackend->createCalendar(
+            'principals/user1',
+            'default',
+            [
+               
+            ]
+        );
+
+    }
+
+    function testDelivery() {
+
+        $request = new Request('PUT', '/calendars/user1/default/foo.ics');
+        $request->setBody(<<<ICS
+BEGIN:VCALENDAR
+VERSION:2.0
+PRODID:-//Apple Inc.//Mac OS X 10.9.1//EN
+CALSCALE:GREGORIAN
+BEGIN:VEVENT
+CREATED:20140109T204404Z
+UID:AADC6438-18CF-4B52-8DD2-EF9AD75ADE83
+DTEND;TZID=America/Toronto:20140107T110000
+TRANSP:OPAQUE
+ATTENDEE;CN="Adminstrator";CUTYPE=INDIVIDUAL;PARTSTAT=ACCEPTED:mailto:user1.sabredav at sabredav.org
+ATTENDEE;CN="Roxy Kesh";CUTYPE=INDIVIDUAL;EMAIL="roxannakesh at gmail.com";
+ PARTSTAT=NEEDS-ACTION;ROLE=REQ-PARTICIPANT;RSVP=TRUE:mailto:roxannakesh@
+ gmail.com
+SUMMARY:Just testing!
+DTSTART;TZID=America/Toronto:20140107T100000
+DTSTAMP:20140109T204422Z
+ORGANIZER;CN="Adminstrator":mailto:evertpot at gmail.com
+SEQUENCE:4
+END:VEVENT
+END:VCALENDAR
+ICS
+);
+        $response = $this->request($request);
+        $this->assertEquals(201, $response->getStatus(), 'Incorrect status code received. Response body:' . $response->getBodyAsString());
+        $this->markTestIncomplete('Need to test if the message gets delivered');
+
+    }
+
+}

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/php-sabredav.git



More information about the Pkg-owncloud-commits mailing list