1
0
Fork 0
mirror of https://github.com/Kozea/Radicale.git synced 2025-07-23 17:48:30 +00:00

Set Content-Length for HEAD requests

This commit is contained in:
Unrud 2022-01-15 22:32:38 +01:00
parent a26dcf3188
commit 2a29ad6a17
3 changed files with 8 additions and 6 deletions

View file

@ -382,8 +382,9 @@ permissions: RrWw""")
assert xml.find(xmlutils.make_clark("C:no-uid-conflict")) is not None
def test_head(self) -> None:
status, _, _ = self.request("HEAD", "/")
status, headers, answer = self.request("HEAD", "/")
assert status == 302
assert int(headers.get("Content-Length", "0")) > 0 and not answer
def test_options(self) -> None:
status, headers, _ = self.request("OPTIONS", "/")