diff --git a/test/test_http_connection.cpp b/test/test_http_connection.cpp index 898ec94d5..eedb0bfd9 100644 --- a/test/test_http_connection.cpp +++ b/test/test_http_connection.cpp @@ -197,7 +197,6 @@ int test_main() TEST_CHECK(!ec); if (ec) fprintf(stderr, "file error: %s\n", ec.message().c_str()); test_file.close(); - std::system("gzip -9 -c test_file > test_file.gz"); proxy_settings ps; ps.hostname = "127.0.0.1"; diff --git a/test/web_server.py b/test/web_server.py index d977471b3..02590423b 100644 --- a/test/web_server.py +++ b/test/web_server.py @@ -3,9 +3,16 @@ import SimpleHTTPServer import sys import os import ssl +import gzip chunked_encoding = False +fin = open('test_file', 'rb') +f = gzip.open('test_file.gz', 'wb') +f.writelines(fin) +f.close() +fin.close() + class http_server_with_timeout(BaseHTTPServer.HTTPServer): allow_reuse_address = True timeout = 120