[CalendarServer-changes] [8649] CalDAVTester/trunk
source_changes at macosforge.org
source_changes at macosforge.org
Sat Feb 11 12:13:59 PST 2012
Revision: 8649
http://trac.macosforge.org/projects/calendarserver/changeset/8649
Author: cdaboo at apple.com
Date: 2012-02-11 12:13:58 -0800 (Sat, 11 Feb 2012)
Log Message:
-----------
Test that calendar color is copied over during direct share.
Modified Paths:
--------------
CalDAVTester/trunk/scripts/tests/CalDAV/sharing-create.xml
CalDAVTester/trunk/scripts/tests/CalDAV/sharing-direct.xml
Added Paths:
-----------
CalDAVTester/trunk/Resource/CalDAV/sharing/direct/
CalDAVTester/trunk/Resource/CalDAV/sharing/direct/1.xml
CalDAVTester/trunk/Resource/CalDAV/sharing/direct/2.xml
Added: CalDAVTester/trunk/Resource/CalDAV/sharing/direct/1.xml
===================================================================
--- CalDAVTester/trunk/Resource/CalDAV/sharing/direct/1.xml (rev 0)
+++ CalDAVTester/trunk/Resource/CalDAV/sharing/direct/1.xml 2012-02-11 20:13:58 UTC (rev 8649)
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<D:propertyupdate xmlns:D="DAV:" xmlns:IC="http://apple.com/ns/ical/">
+<D:set>
+<D:prop>
+<IC:calendar-color>#00112233</IC:calendar-color>
+</D:prop>
+</D:set>
+</D:propertyupdate>
Added: CalDAVTester/trunk/Resource/CalDAV/sharing/direct/2.xml
===================================================================
--- CalDAVTester/trunk/Resource/CalDAV/sharing/direct/2.xml (rev 0)
+++ CalDAVTester/trunk/Resource/CalDAV/sharing/direct/2.xml 2012-02-11 20:13:58 UTC (rev 8649)
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<D:propfind xmlns:D="DAV:" xmlns:IC="http://apple.com/ns/ical/">
+<D:prop>
+<IC:calendar-color/>
+</D:prop>
+</D:propfind>
Modified: CalDAVTester/trunk/scripts/tests/CalDAV/sharing-create.xml
===================================================================
--- CalDAVTester/trunk/scripts/tests/CalDAV/sharing-create.xml 2012-02-10 19:46:44 UTC (rev 8648)
+++ CalDAVTester/trunk/scripts/tests/CalDAV/sharing-create.xml 2012-02-11 20:13:58 UTC (rev 8649)
@@ -52,7 +52,26 @@
</verify>
</request>
</test>
+ <test name='2' ignore='no'>
+ <description>Change the color</description>
+ <request print-response="no">
+ <method>PROPPATCH</method>
+ <ruri>$calendarhome1:/shared/</ruri>
+ <data>
+ <content-type>text/xml; charset=utf-8</content-type>
+ <filepath>Resource/CalDAV/sharing/direct/1.xml</filepath>
+ </data>
+ <verify>
+ <callback>propfindItems</callback>
+ <arg>
+ <name>okprops</name>
+ <value>{http://apple.com/ns/ical/}calendar-color</value>
+ </arg>
+ </verify>
+ </request>
+ </test>
</test-suite>
+
<test-suite name='Generate invite' ignore='no'>
<test name='1' ignore='no'>
<description>POST invitation</description>
@@ -121,6 +140,10 @@
<verify>
<callback>statusCode</callback>
</verify>
+ <grabelement>
+ <name>{DAV:}href</name>
+ <variable>$sharedcalendar2:</variable>
+ </grabelement>
</request>
</test>
<test name='2' ignore='no'>
@@ -163,6 +186,28 @@
</verify>
</request>
</test>
+ <test name='4'>
+ <description>Shared calendar exists without color</description>
+ <request user="$userid2:" pswd="$pswd2:" print-response='no'>
+ <method>PROPFIND</method>
+ <ruri>$sharedcalendar2:/</ruri>
+ <header>
+ <name>Depth</name>
+ <value>0</value>
+ </header>
+ <data>
+ <content-type>text/xml; charset=utf-8</content-type>
+ <filepath>Resource/CalDAV/sharing/direct/2.xml</filepath>
+ </data>
+ <verify>
+ <callback>propfindItems</callback>
+ <arg>
+ <name>badprops</name>
+ <value>{http://apple.com/ns/ical/}calendar-color</value>
+ </arg>
+ </verify>
+ </request>
+ </test>
</test-suite>
<end>
Modified: CalDAVTester/trunk/scripts/tests/CalDAV/sharing-direct.xml
===================================================================
--- CalDAVTester/trunk/scripts/tests/CalDAV/sharing-direct.xml 2012-02-10 19:46:44 UTC (rev 8648)
+++ CalDAVTester/trunk/scripts/tests/CalDAV/sharing-direct.xml 2012-02-11 20:13:58 UTC (rev 8649)
@@ -657,6 +657,109 @@
</test>
</test-suite>
+ <test-suite name='Calendar color' ignore='no'>
+ <test name='1' ignore='no'>
+ <description>Add user02 as read write for user01</description>
+ <request print-response="no">
+ <method>PROPPATCH</method>
+ <ruri>$principal1:calendar-proxy-write/</ruri>
+ <data>
+ <content-type>text/xml; charset=utf-8</content-type>
+ <filepath>Resource/CalDAV/calendaruserproxy/3.xml</filepath>
+ </data>
+ <verify>
+ <callback>propfindItems</callback>
+ <arg>
+ <name>okprops</name>
+ <value>{DAV:}group-member-set</value>
+ </arg>
+ </verify>
+ </request>
+ </test>
+ <test name='2' ignore='no'>
+ <description>Change the color</description>
+ <request print-response="no">
+ <method>PROPPATCH</method>
+ <ruri>$calendarhomealt1:/shared/</ruri>
+ <data>
+ <content-type>text/xml; charset=utf-8</content-type>
+ <filepath>Resource/CalDAV/sharing/direct/1.xml</filepath>
+ </data>
+ <verify>
+ <callback>propfindItems</callback>
+ <arg>
+ <name>okprops</name>
+ <value>{http://apple.com/ns/ical/}calendar-color</value>
+ </arg>
+ </verify>
+ </request>
+ </test>
+ <test name='3'>
+ <description>Sharee does direct share</description>
+ <request user="$userid2:" pswd="$pswd2:" print-response='no'>
+ <method>GET</method>
+ <ruri>$calendarhomealt1:/shared/?action=share</ruri>
+ <verify>
+ <callback>statusCode</callback>
+ </verify>
+ <grabelement>
+ <name>{DAV:}href</name>
+ <variable>$sharedcalendar2:</variable>
+ </grabelement>
+ </request>
+ </test>
+ <test name='4'>
+ <description>Shared calendar exists with color</description>
+ <request user="$userid2:" pswd="$pswd2:" print-response='no'>
+ <method>PROPFIND</method>
+ <ruri>$sharedcalendar2:/</ruri>
+ <header>
+ <name>Depth</name>
+ <value>0</value>
+ </header>
+ <data>
+ <content-type>text/xml; charset=utf-8</content-type>
+ <filepath>Resource/CalDAV/sharing/direct/2.xml</filepath>
+ </data>
+ <verify>
+ <callback>xmlElementMatch</callback>
+ <arg>
+ <name>exists</name>
+ <value>$verify-property-prefix:/{http://apple.com/ns/ical/}calendar-color[=#00112233]</value>
+ </arg>
+ </verify>
+ </request>
+ </test>
+ <test name='5' ignore='no'>
+ <description>Remove direct share</description>
+ <request user="$userid2:" pswd="$pswd2:" print-response="no">
+ <method>DELETE</method>
+ <ruri>$sharedcalendar2:/</ruri>
+ <verify>
+ <callback>statusCode</callback>
+ </verify>
+ </request>
+ </test>
+ <test name='6' ignore='no'>
+ <description>Clear user02 as read-write proxy for user01</description>
+ <request print-response="no">
+ <method>PROPPATCH</method>
+ <ruri>$principal1:calendar-proxy-write/</ruri>
+ <data>
+ <content-type>text/xml; charset=utf-8</content-type>
+ <filepath>Resource/CalDAV/calendaruserproxy/4.xml</filepath>
+ </data>
+ <verify>
+ <callback>propfindItems</callback>
+ <arg>
+ <name>okprops</name>
+ <value>{DAV:}group-member-set</value>
+ </arg>
+ </verify>
+ </request>
+ </test>
+ </test-suite>
+
<end/>
</caldavtest>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20120211/cd96304a/attachment.html>
More information about the calendarserver-changes
mailing list