Reject CalDAV writeback events without uid (#1582)

This commit is contained in:
red person
2026-06-03 02:57:15 +03:00
committed by GitHub
parent 0ad5cd783b
commit 8051e25c65
2 changed files with 11 additions and 1 deletions
+7
View File
@@ -116,3 +116,10 @@ def test_push_unknown_calendar_reports_not_found():
cal = FakeCalendar("https://different/")
res = push_event([cal], CAL_ID, _ev())
assert res["ok"] is False and "not found" in res["error"]
def test_push_missing_uid_reports_input_error_before_remote_lookup():
cal = FakeCalendar(REMOTE_URL, existing=FakeEvent())
res = push_event([cal], CAL_ID, _ev(uid=""))
assert res["ok"] is False and "uid" in res["error"]
assert cal._existing.saved is False