diff options
author | Maximilian Hils <git@maximilianhils.com> | 2016-09-21 21:00:07 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-09-21 21:00:07 -0700 |
commit | d5427c7298b0c6aee009a86dec041011427689e9 (patch) | |
tree | 00b84f3a616c1c2c6e3469c2fb2a0be4a9d5e265 /test/netlib/test_strutils.py | |
parent | 1e5a5b03f8d56df62a04a368bd5eb2d59cb7582a (diff) | |
parent | f1d519d7c4231513c868179abf0fbfbb9387e633 (diff) | |
download | mitmproxy-d5427c7298b0c6aee009a86dec041011427689e9.tar.gz mitmproxy-d5427c7298b0c6aee009a86dec041011427689e9.tar.bz2 mitmproxy-d5427c7298b0c6aee009a86dec041011427689e9.zip |
Merge pull request #1563 from mhils/fix-1562
Raise TypeError on invalid header assignment, fix #1562
Diffstat (limited to 'test/netlib/test_strutils.py')
-rw-r--r-- | test/netlib/test_strutils.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/test/netlib/test_strutils.py b/test/netlib/test_strutils.py index 5be254a3..0f58cac5 100644 --- a/test/netlib/test_strutils.py +++ b/test/netlib/test_strutils.py @@ -8,6 +8,8 @@ def test_always_bytes(): assert strutils.always_bytes("foo") == b"foo" with tutils.raises(ValueError): strutils.always_bytes(u"\u2605", "ascii") + with tutils.raises(TypeError): + strutils.always_bytes(42, "ascii") def test_native(): |