From 7f28f69452d3c6250d7efdad85eb38464016b7a8 Mon Sep 17 00:00:00 2001 From: Peter Bieringer Date: Fri, 22 Aug 2025 07:51:15 +0200 Subject: [PATCH] extend test for items having tzinfo only on dtstart or dtend set for whatever reason, overtake tzinfo from the other one --- radicale/tests/test_base.py | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/radicale/tests/test_base.py b/radicale/tests/test_base.py index eb25bd1f..a9d0acc7 100644 --- a/radicale/tests/test_base.py +++ b/radicale/tests/test_base.py @@ -306,6 +306,22 @@ permissions: RrWw""") for uid2 in uids[i + 1:]: assert uid1 != uid2 + def test_add_event_tz_dtend_only(self) -> None: + """Add an event having TZ only on DTEND.""" + self.mkcalendar("/calendar.ics/") + event = get_file_content("event_issue1847_1.ics") + path = "/calendar.ics/event_issue1847_1.ics" + self.put(path, event) + _, headers, answer = self.request("GET", path, check=200) + + def test_add_event_tz_dtstart_only(self) -> None: + """Add an event having TZ only on DTSTART.""" + self.mkcalendar("/calendar.ics/") + event = get_file_content("event_issue1847_2.ics") + path = "/calendar.ics/event_issue1847_2.ics" + self.put(path, event) + _, headers, answer = self.request("GET", path, check=200) + def test_verify(self) -> None: """Verify the storage.""" contacts = get_file_content("contact_multiple.vcf")