[CalendarServer-changes] [3208] CalDAVTester/trunk

source_changes at macosforge.org source_changes at macosforge.org
Wed Oct 22 11:22:22 PDT 2008


Revision: 3208
          http://trac.macosforge.org/projects/calendarserver/changeset/3208
Author:   sagen at apple.com
Date:     2008-10-22 11:22:22 -0700 (Wed, 22 Oct 2008)
Log Message:
-----------
Tests for principal-property-search

Modified Paths:
--------------
    CalDAVTester/trunk/scripts/tests/aclreports.xml

Added Paths:
-----------
    CalDAVTester/trunk/Resource/aclreports/21.xml
    CalDAVTester/trunk/Resource/aclreports/22.xml
    CalDAVTester/trunk/Resource/aclreports/23.xml
    CalDAVTester/trunk/Resource/aclreports/24.xml

Added: CalDAVTester/trunk/Resource/aclreports/21.xml
===================================================================
--- CalDAVTester/trunk/Resource/aclreports/21.xml	                        (rev 0)
+++ CalDAVTester/trunk/Resource/aclreports/21.xml	2008-10-22 18:22:22 UTC (rev 3208)
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<D:principal-property-search xmlns:D="DAV:" xmlns:c="http://calendarserver.org/ns/" test="allof" type="INDIVIDUAL">
+ <D:apply-to-principal-collection-set/>
+ <D:property-search>
+   <D:prop>
+     <c:first-name/>
+   </D:prop>
+   <D:match match-type="starts-with">appren</D:match>
+ </D:property-search>
+ <D:property-search>
+   <D:prop>
+     <c:last-name/>
+   </D:prop>
+   <D:match match-type="contains">uper</D:match>
+ </D:property-search>
+ <D:prop>
+   <D:displayname/>
+   <c:first-name/>
+   <c:last-name/>
+   <c:email-address-set/>
+ </D:prop>
+</D:principal-property-search>

Added: CalDAVTester/trunk/Resource/aclreports/22.xml
===================================================================
--- CalDAVTester/trunk/Resource/aclreports/22.xml	                        (rev 0)
+++ CalDAVTester/trunk/Resource/aclreports/22.xml	2008-10-22 18:22:22 UTC (rev 3208)
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<D:principal-property-search xmlns:D="DAV:" xmlns:c="http://calendarserver.org/ns/" test="anyof" type="INDIVIDUAL">
+ <D:apply-to-principal-collection-set/>
+ <D:property-search>
+   <D:prop>
+     <c:first-name/>
+   </D:prop>
+   <D:match match-type="starts-with">appren</D:match>
+ </D:property-search>
+ <D:property-search>
+   <D:prop>
+     <c:last-name/>
+   </D:prop>
+   <D:match match-type="contains">user</D:match>
+ </D:property-search>
+ <D:prop>
+   <D:displayname/>
+   <c:first-name/>
+   <c:last-name/>
+   <c:email-address-set/>
+ </D:prop>
+</D:principal-property-search>

Added: CalDAVTester/trunk/Resource/aclreports/23.xml
===================================================================
--- CalDAVTester/trunk/Resource/aclreports/23.xml	                        (rev 0)
+++ CalDAVTester/trunk/Resource/aclreports/23.xml	2008-10-22 18:22:22 UTC (rev 3208)
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<D:principal-property-search xmlns:D="DAV:" xmlns:c="http://calendarserver.org/ns/" test="anyof" type="ROOM">
+ <D:apply-to-principal-collection-set/>
+ <D:property-search>
+   <D:prop>
+     <D:displayname/>
+   </D:prop>
+   <D:match match-type="contains">03</D:match>
+ </D:property-search>
+ <D:prop>
+   <D:displayname/>
+ </D:prop>
+</D:principal-property-search>

Added: CalDAVTester/trunk/Resource/aclreports/24.xml
===================================================================
--- CalDAVTester/trunk/Resource/aclreports/24.xml	                        (rev 0)
+++ CalDAVTester/trunk/Resource/aclreports/24.xml	2008-10-22 18:22:22 UTC (rev 3208)
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<D:principal-property-search xmlns:D="DAV:" xmlns:c="http://calendarserver.org/ns/" test="anyof" type="RESOURCE">
+ <D:apply-to-principal-collection-set/>
+ <D:property-search>
+   <D:prop>
+     <D:displayname/>
+   </D:prop>
+   <D:match match-type="contains">03</D:match>
+ </D:property-search>
+ <D:prop>
+   <D:displayname/>
+ </D:prop>
+</D:principal-property-search>

Modified: CalDAVTester/trunk/scripts/tests/aclreports.xml
===================================================================
--- CalDAVTester/trunk/scripts/tests/aclreports.xml	2008-10-22 17:03:26 UTC (rev 3207)
+++ CalDAVTester/trunk/scripts/tests/aclreports.xml	2008-10-22 18:22:22 UTC (rev 3208)
@@ -495,6 +495,95 @@
 				</verify>
 			</request>
 		</test>
+		<test name='7' ignore='no'>
+			<description>Valid INDIVIDUAL first-name AND last-name search report</description>
+			<request print-response='no' user='$useradmin:' pswd='$pswdadmin:'>
+				<method>REPORT</method>
+				<ruri>1.ics</ruri>
+				<data>
+					<content-type>text/xml; charset=utf-8</content-type>
+					<filepath>Resource/aclreports/21.xml</filepath>
+				</data>
+				<verify>
+					<callback>multistatusItems</callback>
+					<arg>
+						<name>prefix</name>
+						<value/>
+					</arg>
+					<arg>
+						<name>okhrefs</name>
+						<value>$uids:apprentice/</value>
+					</arg>
+				</verify>
+			</request>
+		</test>
+		<test name='8' ignore='no'>
+			<description>Valid INDIVIDUAL first-name OR last-name search report</description>
+			<request print-response='no' user='$useradmin:' pswd='$pswdadmin:'>
+				<method>REPORT</method>
+				<ruri>1.ics</ruri>
+				<data>
+					<content-type>text/xml; charset=utf-8</content-type>
+					<filepath>Resource/aclreports/22.xml</filepath>
+				</data>
+				<verify>
+					<callback>multistatusItems</callback>
+					<arg>
+						<name>prefix</name>
+						<value/>
+					</arg>
+					<arg>
+						<name>okhrefs</name>
+						<value>$uids:admin/</value>
+						<value>$uids:apprentice/</value>
+					</arg>
+				</verify>
+			</request>
+		</test>
+		<test name='9' ignore='no'>
+			<description>Valid ROOM displayname search report</description>
+			<request print-response='no' user='$useradmin:' pswd='$pswdadmin:'>
+				<method>REPORT</method>
+				<ruri>1.ics</ruri>
+				<data>
+					<content-type>text/xml; charset=utf-8</content-type>
+					<filepath>Resource/aclreports/23.xml</filepath>
+				</data>
+				<verify>
+					<callback>multistatusItems</callback>
+					<arg>
+						<name>prefix</name>
+						<value/>
+					</arg>
+					<arg>
+						<name>okhrefs</name>
+						<value>$uids:location03/</value>
+					</arg>
+				</verify>
+			</request>
+		</test>
+		<test name='10' ignore='no'>
+			<description>Valid RESOURCE displayname search report</description>
+			<request print-response='no' user='$useradmin:' pswd='$pswdadmin:'>
+				<method>REPORT</method>
+				<ruri>1.ics</ruri>
+				<data>
+					<content-type>text/xml; charset=utf-8</content-type>
+					<filepath>Resource/aclreports/24.xml</filepath>
+				</data>
+				<verify>
+					<callback>multistatusItems</callback>
+					<arg>
+						<name>prefix</name>
+						<value/>
+					</arg>
+					<arg>
+						<name>okhrefs</name>
+						<value>$uids:resource03/</value>
+					</arg>
+				</verify>
+			</request>
+		</test>
 	</test-suite>
 	
 	<test-suite name='principal-search-property-set REPORT' ignore='no'>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20081022/60a1bf6c/attachment.html>


More information about the calendarserver-changes mailing list