Bug 1435781 - Part 1: Prevent content sniffing of the response in original echo-content.py, r=nika
MozReview-Commit-ID: DVHdrtERYhY
--- a/testing/web-platform/tests/fetch/api/resources/echo-content.py
+++ b/testing/web-platform/tests/fetch/api/resources/echo-content.py
@@ -1,9 +1,9 @@
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"))]
-
+ # Avoid any kind of content sniffing on the response.
+ ("Content-Type", "text/plain")]
content = request.body
return headers, content