[Pkg-owncloud-commits] [php-sabre-vobject] 03/10: Added test case for #306.
David Prévot
taffit at moszumanska.debian.org
Thu Apr 7 01:41:25 UTC 2016
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch 3
in repository php-sabre-vobject.
commit 3843882db06f54e654696208fb9dddfbe43341ba
Author: Evert Pot <me at evertpot.com>
Date: Tue Mar 29 21:42:15 2016 -0400
Added test case for #306.
Fixes #306.
Closes #308.
---
ChangeLog.md | 2 +-
lib/ITip/Broker.php | 12 ++++--
tests/VObject/ITip/BrokerProcessReplyTest.php | 61 +++++++++++++++++++++++++++
3 files changed, 71 insertions(+), 4 deletions(-)
diff --git a/ChangeLog.md b/ChangeLog.md
index 07696ab..6669507 100644
--- a/ChangeLog.md
+++ b/ChangeLog.md
@@ -4,7 +4,7 @@ ChangeLog
3.5.1 (????-??-??)
------------------
-* #306: When expanding recurring events, the first event should also have a
+* #309: When expanding recurring events, the first event should also have a
`RECURRENCE-ID` property.
diff --git a/lib/ITip/Broker.php b/lib/ITip/Broker.php
index 7a24877..e439196 100644
--- a/lib/ITip/Broker.php
+++ b/lib/ITip/Broker.php
@@ -807,9 +807,15 @@ class Broker {
* 1. uid
* 2. organizer
* 3. organizerName
- * 4. attendees
- * 5. instances
- *
+ * 4. organizerScheduleAgent
+ * 5. organizerForceSend
+ * 6. instances
+ * 7. attendees
+ * 8. sequence
+ * 9. exdate
+ * 10. timezone
+ * 11. significantChangeHash
+ * 12. status
* @param VCalendar $calendar
* @return array
*/
diff --git a/tests/VObject/ITip/BrokerProcessReplyTest.php b/tests/VObject/ITip/BrokerProcessReplyTest.php
index a76bd43..533fdce 100644
--- a/tests/VObject/ITip/BrokerProcessReplyTest.php
+++ b/tests/VObject/ITip/BrokerProcessReplyTest.php
@@ -432,4 +432,65 @@ ICS;
}
+ function testReplyNewExceptionFirstOccurence() {
+
+ // This is a reply to 1 instance of a recurring event. This should
+ // automatically create an exception.
+ $itip = <<<ICS
+BEGIN:VCALENDAR
+VERSION:2.0
+METHOD:REPLY
+BEGIN:VEVENT
+ATTENDEE;PARTSTAT=ACCEPTED:mailto:foo at example.org
+ORGANIZER:mailto:bar at example.org
+SEQUENCE:2
+RECURRENCE-ID:20140724T000000Z
+UID:foobar
+END:VEVENT
+END:VCALENDAR
+ICS;
+
+ $old = <<<ICS
+BEGIN:VCALENDAR
+VERSION:2.0
+BEGIN:VEVENT
+SEQUENCE:2
+UID:foobar
+RRULE:FREQ=DAILY
+DTSTART:20140724T000000Z
+DTEND:20140724T010000Z
+ATTENDEE:mailto:foo at example.org
+ORGANIZER:mailto:bar at example.org
+END:VEVENT
+END:VCALENDAR
+ICS;
+
+ $expected = <<<ICS
+BEGIN:VCALENDAR
+VERSION:2.0
+BEGIN:VEVENT
+SEQUENCE:2
+UID:foobar
+RRULE:FREQ=DAILY
+DTSTART:20140724T000000Z
+DTEND:20140724T010000Z
+ATTENDEE:mailto:foo at example.org
+ORGANIZER:mailto:bar at example.org
+END:VEVENT
+BEGIN:VEVENT
+SEQUENCE:2
+UID:foobar
+DTSTART:20140724T000000Z
+DTEND:20140724T010000Z
+ATTENDEE;PARTSTAT=ACCEPTED:mailto:foo at example.org
+ORGANIZER:mailto:bar at example.org
+RECURRENCE-ID:20140724T000000Z
+END:VEVENT
+END:VCALENDAR
+ICS;
+
+ $result = $this->process($itip, $old, $expected);
+
+ }
+
}
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-php/php-sabre-vobject.git
More information about the Pkg-owncloud-commits
mailing list