diff options
author | Maximilian Hils <git@maximilianhils.com> | 2016-07-15 23:46:12 -0700 |
---|---|---|
committer | Maximilian Hils <git@maximilianhils.com> | 2016-07-15 23:46:12 -0700 |
commit | e6e39ce80f4daaf6a1d6f8d87616409486d358a5 (patch) | |
tree | 1db9f3a18986aa84a8a516ab594aaba9f60671f4 /test/netlib | |
parent | 3602fd7a36d963311339ab11ed36ff00df860f71 (diff) | |
download | mitmproxy-e6e39ce80f4daaf6a1d6f8d87616409486d358a5.tar.gz mitmproxy-e6e39ce80f4daaf6a1d6f8d87616409486d358a5.tar.bz2 mitmproxy-e6e39ce80f4daaf6a1d6f8d87616409486d358a5.zip |
preserve content-type parameter order
Diffstat (limited to 'test/netlib')
-rw-r--r-- | test/netlib/http/test_headers.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/test/netlib/http/test_headers.py b/test/netlib/http/test_headers.py index 8462a5af..51537310 100644 --- a/test/netlib/http/test_headers.py +++ b/test/netlib/http/test_headers.py @@ -1,3 +1,5 @@ +import collections + from netlib.http.headers import Headers, parse_content_type, assemble_content_type from netlib.tutils import raises @@ -87,4 +89,4 @@ def test_assemble_content_type(): p = assemble_content_type assert p("text", "html", {}) == "text/html" assert p("text", "html", {"charset": "utf8"}) == "text/html; charset=utf8" - assert p("text", "html", {"charset": "utf8", "foo": "bar"}) == "text/html; charset=utf8; foo=bar" + assert p("text", "html", collections.OrderedDict([("charset", "utf8"), ("foo", "bar")])) == "text/html; charset=utf8; foo=bar" |