[CalendarServer-changes] [14791] CalDAVTester/trunk/scripts/tests/CalDAV/options.xml

source_changes at macosforge.org source_changes at macosforge.org
Sun May 17 23:28:50 PDT 2015


Revision: 14791
          http://trac.calendarserver.org//changeset/14791
Author:   cdaboo at apple.com
Date:     2015-05-17 23:28:50 -0700 (Sun, 17 May 2015)
Log Message:
-----------
Test OPTIONS requests and DAV header only on OPTIONS.

Added Paths:
-----------
    CalDAVTester/trunk/scripts/tests/CalDAV/options.xml

Added: CalDAVTester/trunk/scripts/tests/CalDAV/options.xml
===================================================================
--- CalDAVTester/trunk/scripts/tests/CalDAV/options.xml	                        (rev 0)
+++ CalDAVTester/trunk/scripts/tests/CalDAV/options.xml	2015-05-18 06:28:50 UTC (rev 14791)
@@ -0,0 +1,122 @@
+<?xml version="1.0" standalone="no"?>
+
+<!DOCTYPE caldavtest SYSTEM "caldavtest.dtd">
+
+<!--
+ Copyright (c) 2015 Apple Inc. All rights reserved.
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<caldavtest>
+	<description>Test OPTIONS, DAV header behavior</description>
+
+	<require-feature>
+		<feature>caldav</feature>
+	</require-feature>
+
+	<start/>
+	
+	<test-suite name='OPTIONS+DAV'>
+		<test name='1'>
+			<description>OPTIONS on calendar home returns DAV header</description>
+			<request>
+				<method>OPTIONS</method>
+				<ruri>$calendarhome1:/</ruri>
+				<verify>
+					<callback>statusCode</callback>
+				</verify>
+				<verify>
+					<callback>header</callback>
+					<arg>
+						<name>header</name>
+						<value>DAV</value>
+					</arg>
+				</verify>
+			</request>
+		</test>
+		<test name='2'>
+			<description>OPTIONS on principal returns DAV header</description>
+			<request>
+				<method>OPTIONS</method>
+				<ruri>$calendarhome1:/</ruri>
+				<verify>
+					<callback>statusCode</callback>
+				</verify>
+				<verify>
+					<callback>header</callback>
+					<arg>
+						<name>header</name>
+						<value>DAV</value>
+					</arg>
+				</verify>
+			</request>
+		</test>
+	</test-suite>
+
+	<test-suite name='PROPFIND - no DAV'>
+		<test name='1'>
+			<description>PROPFIND on calendar home does not return DAV header</description>
+			<request>
+				<method>PROPFIND</method>
+				<ruri>$calendarhome1:/</ruri>
+				<header>
+					<name>Depth</name>
+					<value>0</value>
+				</header>
+				<data>
+					<content-type>text/xml; charset=utf-8</content-type>
+					<filepath>Resource/Common/PROPFIND/props.xml</filepath>
+				</data>
+				<verify>
+					<callback>statusCode</callback>
+				</verify>
+				<verify>
+					<callback>header</callback>
+					<arg>
+						<name>header</name>
+						<value>!DAV</value>
+					</arg>
+				</verify>
+			</request>
+		</test>
+		<test name='2'>
+			<description>PROPFIND on principal does not return DAV header</description>
+			<request>
+				<method>PROPFIND</method>
+				<ruri>$calendarhome1:/</ruri>
+				<header>
+					<name>Depth</name>
+					<value>0</value>
+				</header>
+				<data>
+					<content-type>text/xml; charset=utf-8</content-type>
+					<filepath>Resource/Common/PROPFIND/props.xml</filepath>
+				</data>
+				<verify>
+					<callback>statusCode</callback>
+				</verify>
+				<verify>
+					<callback>header</callback>
+					<arg>
+						<name>header</name>
+						<value>!DAV</value>
+					</arg>
+				</verify>
+			</request>
+		</test>
+	</test-suite>
+
+	<end/>
+	
+</caldavtest>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20150517/efeca933/attachment-0001.html>


More information about the calendarserver-changes mailing list