diff --git a/radicale/tests/static/event_multiple_case_sensitive_uids.ics b/radicale/tests/static/event_multiple_case_sensitive_uids.ics new file mode 100644 index 0000000..ffca585 --- /dev/null +++ b/radicale/tests/static/event_multiple_case_sensitive_uids.ics @@ -0,0 +1,16 @@ +BEGIN:VCALENDAR +PRODID:-//Mozilla.org/NONSGML Mozilla Calendar V1.1//EN +VERSION:2.0 +BEGIN:VEVENT +UID:event +SUMMARY:Event 1 +DTSTART:20130901T190000 +DTEND:20130901T200000 +END:VEVENT +BEGIN:VEVENT +UID:EVENT +SUMMARY:Event 2 +DTSTART:20130901T200000 +DTEND:20130901T210000 +END:VEVENT +END:VCALENDAR diff --git a/radicale/tests/test_base.py b/radicale/tests/test_base.py index c025493..5ea37bf 100644 --- a/radicale/tests/test_base.py +++ b/radicale/tests/test_base.py @@ -243,6 +243,13 @@ permissions: RrWw""") for uid2 in uids[i + 1:]: assert uid1 != uid2 + def test_put_whole_calendar_case_sensitive_uids(self) -> None: + """Create a whole calendar with case-sensitive UIDs.""" + events = get_file_content("event_multiple_case_sensitive_uids.ics") + self.put("/calendar.ics/", events) + _, answer = self.get("/calendar.ics/") + assert "\r\nUID:event\r\n" in answer and "\r\nUID:EVENT\r\n" in answer + def test_put_whole_addressbook(self) -> None: """Create and overwrite a whole addressbook.""" contacts = get_file_content("contact_multiple.vcf")