diff --git a/tests/compatibility_issues.py b/tests/compatibility_issues.py index d042cec..fbfbb8f 100644 --- a/tests/compatibility_issues.py +++ b/tests/compatibility_issues.py @@ -15,8 +15,11 @@ 'rate_limited': """Pause a bit between each request""", + 'cleanup_calendar': + """Remove everything on the calendar for every test""", + 'no_delete_calendar': - """Not allowed to delete calendars""", + """Not allowed to delete calendars - or calendar ends up in a 'trashbin'""", 'broken_expand': """Server-side expand seems to work, but delivers wrong data (typically missing RECURRENCE-ID)""", diff --git a/tests/test_caldav.py b/tests/test_caldav.py index 0143532..13e5666 100644 --- a/tests/test_caldav.py +++ b/tests/test_caldav.py @@ -617,10 +617,9 @@ def setup_method(self): self.caldav = client(**self.server_params) if self.check_compatibility_flag("rate_limited"): - def delay_decorator(f): def foo(*a, **kwa): - time.sleep(5) + time.sleep(60) return f(*a, **kwa) return foo @@ -689,11 +688,11 @@ def _teardownCalendar(self, name=None, cal_id=None): if self.check_compatibility_flag( "sticky_events" ) or self.check_compatibility_flag("no_delete_calendar"): - try: - for goo in cal.objects(): + for goo in cal.objects(): + try: goo.delete() - except: - pass + except: + pass cal.delete() except: pass @@ -2083,7 +2082,7 @@ def testTodoDatesearch(self): assert len(todos2) == foo ## verify that "expand" works - if not self.check_compatibility_flag("no_recurring"): + if not self.check_compatibility_flag("no_recurring") and not self.check_compatibility_flag("no_recurring_todo"): ## todo1 and todo2 should be the same (todo1 using legacy method) ## todo1 and todo2 tries doing server side expand, with fallback ## to client side expand