[CalendarServer-changes] [5939] CalendarServer/branches/new-store-no-caldavfile-2/twistedcaldav/test /test_validation.py
source_changes at macosforge.org
source_changes at macosforge.org
Mon Jul 26 12:42:54 PDT 2010
Revision: 5939
http://trac.macosforge.org/projects/calendarserver/changeset/5939
Author: glyph at apple.com
Date: 2010-07-26 12:42:54 -0700 (Mon, 26 Jul 2010)
Log Message:
-----------
just use CalDAVResource, apparently it's good enough
Modified Paths:
--------------
CalendarServer/branches/new-store-no-caldavfile-2/twistedcaldav/test/test_validation.py
Modified: CalendarServer/branches/new-store-no-caldavfile-2/twistedcaldav/test/test_validation.py
===================================================================
--- CalendarServer/branches/new-store-no-caldavfile-2/twistedcaldav/test/test_validation.py 2010-07-26 18:56:24 UTC (rev 5938)
+++ CalendarServer/branches/new-store-no-caldavfile-2/twistedcaldav/test/test_validation.py 2010-07-26 19:42:54 UTC (rev 5939)
@@ -24,11 +24,11 @@
from twext.web2.test.test_server import SimpleRequest
from twext.web2.http import HTTPError
-from twistedcaldav.static import CalDAVFile
from twistedcaldav.config import config
from twistedcaldav.ical import Component, Property
from twistedcaldav.method.put_common import StoreCalendarObjectResource
from twistedcaldav.caldavxml import MaxAttendeesPerInstance
+from twistedcaldav.resource import CalDAVResource
class TestCopyMoveValidation(TestCase):
"""
@@ -39,14 +39,11 @@
"""
Set up some CalDAV stuff.
"""
-
- class CalDAVFileWithName(CalDAVFile):
-
- def name(self):
- return self.fp.basename()
- self.destination = CalDAVFileWithName(self.mktemp())
- self.destinationParent = CalDAVFileWithName(self.mktemp())
+ self.destination = CalDAVResource()
+ self.destination.name = lambda : '1'
+ self.destinationParent = CalDAVResource()
+ self.destinationParent.name = lambda : '2'
self.sampleCalendar = Component.fromString("""
BEGIN:VCALENDAR
VERSION:2.0
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20100726/36c935cc/attachment.html>
More information about the calendarserver-changes
mailing list