Update web-platform-tests to revision aa86bfbb569fee92a3176bae68e3b7ec54140a6d

This commit is contained in:
WPT Sync Bot 2020-07-22 08:20:19 +00:00
parent a242913629
commit 4c80634acb
102 changed files with 1207 additions and 360 deletions

View file

@ -1,10 +1,12 @@
from wptserve.utils import isomorphic_encode
def main(request, response):
headers = [("X-Request-Method", request.method),
("X-Request-Content-Length", request.headers.get("Content-Length", "NO")),
("X-Request-Content-Type", request.headers.get("Content-Type", "NO")),
headers = [(b"X-Request-Method", isomorphic_encode(request.method)),
(b"X-Request-Content-Length", request.headers.get(b"Content-Length", b"NO")),
(b"X-Request-Content-Type", request.headers.get(b"Content-Type", b"NO")),
# Avoid any kind of content sniffing on the response.
("Content-Type", "text/plain")]
(b"Content-Type", b"text/plain")]
content = request.body
return headers, content