[CalendarServer-changes] [6389] CalDAVTester/trunk

source_changes at macosforge.org source_changes at macosforge.org
Wed Sep 29 17:16:46 PDT 2010


Revision: 6389
          http://trac.macosforge.org/projects/calendarserver/changeset/6389
Author:   dre at apple.com
Date:     2010-09-29 17:16:45 -0700 (Wed, 29 Sep 2010)
Log Message:
-----------
Reconfigured tests used by internal QA environment; now we run odsetup.py once to create a single server config for both CalDAV and CardDAV tests. Also added two additional test scripts that run the full or abridged suites for each DAV type.

Modified Paths:
--------------
    CalDAVTester/trunk/QuickLook-CalDAV
    CalDAVTester/trunk/QuickLook-CardDAV
    CalDAVTester/trunk/Validation-CalDAV
    CalDAVTester/trunk/Validation-CardDAV
    CalDAVTester/trunk/odsetup.py
    CalDAVTester/trunk/scripts/server/serverinfo-template.xml

Added Paths:
-----------
    CalDAVTester/trunk/QuickLook-All
    CalDAVTester/trunk/Validation-All

Added: CalDAVTester/trunk/QuickLook-All
===================================================================
--- CalDAVTester/trunk/QuickLook-All	                        (rev 0)
+++ CalDAVTester/trunk/QuickLook-All	2010-09-30 00:16:45 UTC (rev 6389)
@@ -0,0 +1,37 @@
+#!/bin/bash
+#
+##
+# Copyright (c) 2009 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.
+##
+#
+# Runs a subset of tests as a quick check that the server is functional.
+#
+
+export PYTHONPATH=/usr/share/caldavd/lib/python
+./testcaldav.py -s scripts/server/serverinfo-caldav.xml \
+CalDAV/caldavIOP.xml \
+CalDAV/errors.xml \
+CalDAV/get.xml \
+CalDAV/ical-client.xml \
+CalDAV/propfind.xml \
+CalDAV/put.xml \
+CalDAV/reports.xml \
+CardDAV/ab-client.xml \
+CardDAV/errors.xml \
+CardDAV/get.xml \
+CardDAV/propfind.xml \
+CardDAV/put.xml \
+CardDAV/reports.xml
+


Property changes on: CalDAVTester/trunk/QuickLook-All
___________________________________________________________________
Added: svn:executable
   + *

Modified: CalDAVTester/trunk/QuickLook-CalDAV
===================================================================
--- CalDAVTester/trunk/QuickLook-CalDAV	2010-09-29 22:28:17 UTC (rev 6388)
+++ CalDAVTester/trunk/QuickLook-CalDAV	2010-09-30 00:16:45 UTC (rev 6389)
@@ -20,4 +20,12 @@
 #
 
 export PYTHONPATH=/usr/share/caldavd/lib/python
-./testcaldav.py -s scripts/server/serverinfo-caldav.xml CalDAV/caldavIOP.xml CalDAV/errors.xml CalDAV/get.xml CalDAV/ical-client.xml CalDAV/propfind.xml CalDAV/put.xml CalDAV/reports.xml
+./testcaldav.py -s scripts/server/serverinfo-caldav.xml \
+	CalDAV/caldavIOP.xml \
+	CalDAV/errors.xml \
+	CalDAV/get.xml \
+	CalDAV/ical-client.xml \
+	CalDAV/propfind.xml \
+	CalDAV/put.xml \
+	CalDAV/reports.xml
+

Modified: CalDAVTester/trunk/QuickLook-CardDAV
===================================================================
--- CalDAVTester/trunk/QuickLook-CardDAV	2010-09-29 22:28:17 UTC (rev 6388)
+++ CalDAVTester/trunk/QuickLook-CardDAV	2010-09-30 00:16:45 UTC (rev 6389)
@@ -20,4 +20,12 @@
 #
 
 export PYTHONPATH=/usr/share/caldavd/lib/python
-./testcaldav.py -s scripts/server/serverinfo-carddav.xml CardDAV/ab-client.xml CardDAV/errors.xml CardDAV/get.xml CardDAV/propfind.xml CardDAV/put.xml CardDAV/reports.xml
+./testcaldav.py -s scripts/server/serverinfo-caldav.xml \
+	CardDAV/ab-client.xml \
+	CardDAV/errors.xml \
+	CardDAV/get.xml \
+	CardDAV/propfind.xml \
+	CardDAV/put.xml \
+	CardDAV/reports.xml
+
+

Added: CalDAVTester/trunk/Validation-All
===================================================================
--- CalDAVTester/trunk/Validation-All	                        (rev 0)
+++ CalDAVTester/trunk/Validation-All	2010-09-30 00:16:45 UTC (rev 6389)
@@ -0,0 +1,28 @@
+#!/bin/bash
+#
+##
+# Copyright (c) 2009 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.
+##
+#
+# Runs a full set of tests for CalDAV and CardDAV to verify that the 
+# server is functional.
+#
+
+export PYTHONPATH=/usr/share/caldavd/lib/python
+./testcaldav.py -s scripts/server/serverinfo-caldav.xml --all \
+	--exclude CalDAV/directory.xml \
+	--exclude CalDAV/proxyauthz.xml \
+	--exclude CalDAV/quota.xml
+ 	--exclude CardDAV/directory.xml	


Property changes on: CalDAVTester/trunk/Validation-All
___________________________________________________________________
Added: svn:executable
   + *

Modified: CalDAVTester/trunk/Validation-CalDAV
===================================================================
--- CalDAVTester/trunk/Validation-CalDAV	2010-09-29 22:28:17 UTC (rev 6388)
+++ CalDAVTester/trunk/Validation-CalDAV	2010-09-30 00:16:45 UTC (rev 6389)
@@ -23,7 +23,6 @@
 ./testcaldav.py -s scripts/server/serverinfo-caldav.xml --all \
 	--subdir CalDAV \
 	--exclude CalDAV/directory.xml \
-	--exclude CalDAV/errors-big-calendars.xml \
 	--exclude CalDAV/proxyauthz.xml \
-	--exclude CalDAV/quota.xml
- 	
+	--exclude CalDAV/quota.xml \
+	--exclude CalDAV/sharing-quota.xml 	

Modified: CalDAVTester/trunk/Validation-CardDAV
===================================================================
--- CalDAVTester/trunk/Validation-CardDAV	2010-09-29 22:28:17 UTC (rev 6388)
+++ CalDAVTester/trunk/Validation-CardDAV	2010-09-30 00:16:45 UTC (rev 6389)
@@ -20,7 +20,7 @@
 #
 
 export PYTHONPATH=/usr/share/caldavd/lib/python
-./testcaldav.py -s scripts/server/serverinfo-carddav.xml --all \
+./testcaldav.py -s scripts/server/serverinfo-caldav.xml --all \
 	--subdir CardDAV \
 	--exclude CardDAV/directory.xml
- 	
\ No newline at end of file
+ 	

Modified: CalDAVTester/trunk/odsetup.py
===================================================================
--- CalDAVTester/trunk/odsetup.py	2010-09-29 22:28:17 UTC (rev 6388)
+++ CalDAVTester/trunk/odsetup.py	2010-09-30 00:16:45 UTC (rev 6389)
@@ -45,10 +45,6 @@
         "config": "/etc/caldavd/caldavd.plist",
         "serverinfo": "scripts/server/serverinfo-caldav.xml"
     },
-    "carddav": {
-        "config": "/etc/carddavd/carddavd.plist",
-        "serverinfo": "scripts/server/serverinfo-carddav.xml"
-    }
 }
 
 base_dir = "../CalendarServer/"
@@ -227,8 +223,6 @@
     -c users  number of user accounts to create (default: 10)
     -v        verbose logging
     -V        very verbose logging
-    --caldav  testing CalDAV server
-    --carddav testing CardDAV server
 """
 
 def cmd(args, input=None, raiseOnFail=True):
@@ -331,6 +325,13 @@
     # No SACLs
     plist["EnableSACLs"] = False
 
+    # Enable CardDAV and CalDAV
+    plist["EnableCardDAV"] = True
+    plist["EnableCalDAV"] = True
+
+    # Needed for CDT
+    plist["EnableAnonymousReadRoot"] = True
+
     writePlist(plist, config)
 
 def patchSudoers(sudoers):
@@ -413,18 +414,13 @@
         largeGuid,
     )
 
-    result = cmd("curl --digest -u %s:%s 'http://%s:8008/calendars/users/%s/'" % (
-        largeCalendarUser,
-        largeCalendarUser,
-        hostname,
-        largeCalendarUser,
-    ), raiseOnFail=False)
+    cmd("mkdir -p \"%s\"" % (docroot))
+    cmd("chown calendar:calendar \"%s\"" % (docroot))
+    for calendar in calendars:
+        cmd("sudo -u calendar mkdir -p \"%s\"" % (path))
+        cmd("sudo -u calendar tar -C \"%s\" -zx -f data/%s.tgz" % (path, calendar,))
+        cmd("chown -R calendar:calendar \"%s\"" % (os.path.join(path, calendar) ,))
 
-    if result[1] == 0:
-        for calendar in calendars:
-            cmd("tar -C %s -zx -f data/%s.tgz" % (path, calendar,))
-            cmd("chown -R calendar:calendar %s" % (os.path.join(path, calendar) ,))
-
 def loadLists(config, path, records):
     if path == "/Places":
         result = cmd(
@@ -607,10 +603,10 @@
 if __name__ == "__main__":
 
     config = None
-    protocol = None
+    protocol = "caldav"
     serverinfo_default = None
     try:
-        options, args = getopt.getopt(sys.argv[1:], "hn:p:u:f:c:vV", ["carddav", "caldav", "old"])
+        options, args = getopt.getopt(sys.argv[1:], "hn:p:u:f:c:vV")
 
         for option, value in options:
             if option == "-h":
@@ -631,23 +627,14 @@
             elif option == "-V":
                 verbose = True
                 veryverbose = True
-            elif option == "--carddav":
-                protocol = "carddav"
-            elif option == "--caldav":
-                protocol = "caldav"
             else:
                 print "Unrecognized option: %s" % (option,)
                 usage()
                 raise ValueError
 
-        if not protocol:
-            print "One of --carddav or --caldav MUST be specified"
-            usage()
-            raise ValueError
-        else:
-            if not config:
-                config = details[protocol]["config"]
-                serverinfo_default = details[protocol]["serverinfo"]
+        if not config:
+            config = details[protocol]["config"]
+            serverinfo_default = details[protocol]["serverinfo"]
             
         if not diradmin_pswd:
             diradmin_pswd = getpass("Password: ")

Modified: CalDAVTester/trunk/scripts/server/serverinfo-template.xml
===================================================================
--- CalDAVTester/trunk/scripts/server/serverinfo-template.xml	2010-09-29 22:28:17 UTC (rev 6388)
+++ CalDAVTester/trunk/scripts/server/serverinfo-template.xml	2010-09-30 00:16:45 UTC (rev 6389)
@@ -72,7 +72,7 @@
 		<feature>carddav</feature> 						<!-- Basic CardDAV feature enabler -->
 		<feature>global-addressbook</feature> 			<!-- Global address book for each user -->
 		<feature>shared-addressbooks</feature>			<!-- Shared address books extension -->
-		<feature>directory-gateway</feature>			<!-- Directory gateway extension -->
+		<!-- <feature>directory-gateway</feature> -->			<!-- Directory gateway extension -->
 
 	</features>
 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20100929/bc4986e7/attachment-0001.html>


More information about the calendarserver-changes mailing list