mirror of
https://github.com/Kozea/Radicale.git
synced 2025-08-01 18:18:31 +00:00
Test PROPPATCH
This commit is contained in:
parent
51bf95f00d
commit
62892e3423
3 changed files with 31 additions and 0 deletions
|
@ -213,6 +213,23 @@ class BaseRequestsMixIn:
|
|||
assert "href>%s</" % calendar_path in answer
|
||||
assert "href>%s</" % event_path in answer
|
||||
|
||||
def test_proppatch(self):
|
||||
"""Write a property and read it back."""
|
||||
self.request("MKCALENDAR", "/calendar.ics/")
|
||||
proppatch = get_file_content("proppatch1.xml")
|
||||
status, headers, answer = self.request(
|
||||
"PROPPATCH", "/calendar.ics/", proppatch)
|
||||
assert status == 207
|
||||
assert "calendar-color" in answer
|
||||
assert "200 OK</status" in answer
|
||||
# Read property back
|
||||
propfind = get_file_content("propfind1.xml")
|
||||
status, headers, answer = self.request(
|
||||
"PROPFIND", "/calendar.ics/", propfind)
|
||||
assert status == 207
|
||||
assert ":calendar-color>#BADA55</" in answer
|
||||
assert "200 OK</status" in answer
|
||||
|
||||
def test_multiple_events_with_same_uid(self):
|
||||
"""Add two events with the same UID."""
|
||||
self.request("MKCOL", "/calendar.ics/")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue