[CalendarServer-changes] [13361] CalendarServer/trunk/txdav/who/test/test_group_attendees.py

source_changes at macosforge.org source_changes at macosforge.org
Tue Apr 22 17:49:35 PDT 2014


Revision: 13361
          http://trac.calendarserver.org//changeset/13361
Author:   gaya at apple.com
Date:     2014-04-22 17:49:34 -0700 (Tue, 22 Apr 2014)
Log Message:
-----------
fix txdav.who.test.test_group_attendees.GroupAttendeeReconciliation.test_groupRemovalFromDirectory test (still fails)

Modified Paths:
--------------
    CalendarServer/trunk/txdav/who/test/test_group_attendees.py

Modified: CalendarServer/trunk/txdav/who/test/test_group_attendees.py
===================================================================
--- CalendarServer/trunk/txdav/who/test/test_group_attendees.py	2014-04-22 23:38:33 UTC (rev 13360)
+++ CalendarServer/trunk/txdav/who/test/test_group_attendees.py	2014-04-23 00:49:34 UTC (rev 13361)
@@ -606,6 +606,29 @@
 END:VCALENDAR
 """
 
+        data_get_3 = """BEGIN:VCALENDAR
+VERSION:2.0
+CALSCALE:GREGORIAN
+PRODID:-//Example Inc.//Example Calendar//EN
+BEGIN:VEVENT
+UID:event1 at ninevah.local
+DTSTART;TZID=US/Eastern:20140101T100000
+DURATION:PT1H
+ATTENDEE;CN=User 01;EMAIL=user01 at example.com;RSVP=TRUE:urn:x-uid:10000000-0000-0000-0000-000000000001
+ATTENDEE;CN=Group 01;CUTYPE=GROUP;EMAIL=group01 at example.com;RSVP=TRUE;SCHEDULE-STATUS=3.7:urn:x-uid:20000000-0000-0000-0000-000000000001
+ATTENDEE;CN=Group 02;CUTYPE=GROUP;EMAIL=group02 at example.com;RSVP=TRUE;SCHEDULE-STATUS=3.7:urn:x-uid:20000000-0000-0000-0000-000000000002
+ATTENDEE;CN=Group 03;CUTYPE=GROUP;EMAIL=group03 at example.com;RSVP=TRUE;SCHEDULE-STATUS=3.7:urn:x-uid:20000000-0000-0000-0000-000000000003
+ATTENDEE;CN=User 06;EMAIL=user06 at example.com;MEMBER="urn:x-uid:20000000-0000-0000-0000-000000000002";PARTSTAT=NEEDS-ACTION;RSVP=TRUE;SCHEDULE-STATUS=1.2:urn:x-uid:10000000-0000-0000-0000-000000000006
+ATTENDEE;CN=User 07;EMAIL=user07 at example.com;MEMBER="urn:x-uid:20000000-0000-0000-0000-000000000003","urn:x-uid:20000000-0000-0000-0000-000000000002";PARTSTAT=NEEDS-ACTION;RSVP=TRUE;SCHEDULE-STATUS=1.2:urn:x-uid:10000000-0000-0000-0000-000000000007
+ATTENDEE;CN=User 08;EMAIL=user08 at example.com;MEMBER="urn:x-uid:20000000-0000-0000-0000-000000000003","urn:x-uid:20000000-0000-0000-0000-000000000002";PARTSTAT=NEEDS-ACTION;RSVP=TRUE;SCHEDULE-STATUS=1.2:urn:x-uid:10000000-0000-0000-0000-000000000008
+ATTENDEE;CN=User 09;EMAIL=user09 at example.com;MEMBER="urn:x-uid:20000000-0000-0000-0000-000000000003";PARTSTAT=NEEDS-ACTION;RSVP=TRUE;SCHEDULE-STATUS=1.2:urn:x-uid:10000000-0000-0000-0000-000000000009
+CREATED:20060101T150000Z
+ORGANIZER;CN=User 01;EMAIL=user01 at example.com:urn:x-uid:10000000-0000-0000-0000-000000000001
+SEQUENCE:2
+SUMMARY:event 1
+END:VEVENT
+END:VCALENDAR"""
+
         unpatchedRecordWithUID = DirectoryService.recordWithUID
 
         @inlineCallbacks
@@ -654,7 +677,6 @@
 
         cal1 = yield self.calendarUnderTest(name="calendar", home="10000000-0000-0000-0000-000000000006")
         cobjs = yield cal1.objectResources()
-        #FIXME: Need schema change to handle case where group comes back
         self.assertEqual(len(cobjs), 1)
         comp1 = yield cobjs[0].componentForUser()
         self.assertTrue("STATUS:CANCELLED" in str(comp1))
@@ -671,9 +693,16 @@
 
         cobj1 = yield self.calendarObjectUnderTest(name="data1.ics", calendar_name="calendar", home="10000000-0000-0000-0000-000000000001")
         vcalendar5 = yield cobj1.component()
-        self._assertICalStrEqual(vcalendar5, data_get_1)
+        self._assertICalStrEqual(vcalendar5, data_get_3)
 
+        cal1 = yield self.calendarUnderTest(name="calendar", home="10000000-0000-0000-0000-000000000006")
+        cobjs = yield cal1.objectResources()
+        self.assertEqual(len(cobjs), 1)
+        comp1 = yield cobjs[0].componentForUser()
+        self.assertFalse("STATUS:CANCELLED" in str(comp1))
+        yield self.commit()
 
+
     @inlineCallbacks
     def test_groupRemovalFromEvent(self):
         """
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20140422/dd442ab6/attachment.html>


More information about the calendarserver-changes mailing list