summaryrefslogtreecommitdiffstats
path: root/tests/unit/test-003-event.py
diff options
context:
space:
mode:
authorThomas Bruederli <bruederli@kolabsys.com>2015-02-10 09:44:05 +0100
committerThomas Bruederli <bruederli@kolabsys.com>2015-02-10 09:44:05 +0100
commita214f29290f4d5e5a2d62a8a549679c8a4c0fe51 (patch)
tree5808111ed8491357b7e362b7ad5c79c096ac1172 /tests/unit/test-003-event.py
parent21c116a670c3a34a1e084e1af7c75541a1783f27 (diff)
downloadpykolab-a214f29290f4d5e5a2d62a8a549679c8a4c0fe51.tar.gz
Fix iCal event parsing + unit tests after commit 21c116a
Diffstat (limited to 'tests/unit/test-003-event.py')
-rw-r--r--tests/unit/test-003-event.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/unit/test-003-event.py b/tests/unit/test-003-event.py
index 02bc8df..67481e3 100644
--- a/tests/unit/test-003-event.py
+++ b/tests/unit/test-003-event.py
@@ -369,7 +369,7 @@ METHOD:REQUEST
""" + ical_event + "END:VCALENDAR"
ical = icalendar.Calendar.from_ical(ical_str)
- event = event_from_ical(ical.walk('VEVENT')[0].to_ical())
+ event = event_from_ical(ical.walk('VEVENT')[0], ical_str)
self.assertEqual(event.get_location(), "Location")
self.assertEqual(str(event.get_lastmodified()), "2014-04-07 12:23:11+00:00")
@@ -384,7 +384,7 @@ METHOD:REQUEST
self.assertTrue(event.is_recurring())
self.assertIsInstance(event.get_duration(), datetime.timedelta)
self.assertIsInstance(event.get_end(), datetime.datetime)
- self.assertEqual(str(event.get_end()), "2014-05-23 12:30:00+01:00")
+ self.assertEqual(str(event.get_end()), "2014-05-23 12:30:00+02:00")
self.assertEqual(len(event.get_exception_dates()), 2)
self.assertIsInstance(event.get_exception_dates()[0], datetime.datetime)
self.assertEqual(len(event.get_alarms()), 1)
@@ -632,7 +632,7 @@ END:VEVENT
self.assertEqual(data['attach'][0]['fmttype'], 'text/html')
self.assertIsInstance(data['rrule'], dict)
- self.assertEqual(data['rrule']['frequency'], 'DAILY')
+ self.assertEqual(data['rrule']['freq'], 'DAILY')
self.assertEqual(data['rrule']['interval'], 1)
self.assertEqual(data['rrule']['wkst'], 'MO')
self.assertIsInstance(data['rrule']['until'], datetime.date)