mirror of
https://github.com/servo/servo.git
synced 2025-08-03 20:50:07 +01:00
Update web-platform-tests to revision e8bfc205e36ad699601212cd50083870bad9a75d
This commit is contained in:
parent
65dd6d4340
commit
ccdb0a3458
1428 changed files with 118036 additions and 9786 deletions
|
@ -0,0 +1,17 @@
|
|||
import gzip as gzip_module
|
||||
from cStringIO import StringIO
|
||||
|
||||
def main(request, response):
|
||||
f = open('resource-timing/resources/resource_timing_test0.xml', 'r')
|
||||
output = f.read()
|
||||
|
||||
out = StringIO()
|
||||
with gzip_module.GzipFile(fileobj=out, mode="w") as f:
|
||||
f.write(output)
|
||||
output = out.getvalue()
|
||||
|
||||
headers = [("Content-type", "text/plain"),
|
||||
("Content-Encoding", "gzip"),
|
||||
("Content-Length", len(output))]
|
||||
|
||||
return headers, output
|
Loading…
Add table
Add a link
Reference in a new issue