diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2018-04-24 20:33:09 +0300 |
---|---|---|
committer | Serhiy Storchaka <storchaka@gmail.com> | 2018-04-24 20:33:09 +0300 |
commit | 51b69877435b8503b0400eb54461cded7f103ecb (patch) | |
tree | 758e02aac0991f7b220d0e50039b6f3358943122 /simplejson/tests/test_dump.py | |
parent | 729945a655b2c351ad4c91293a494c066f3bb152 (diff) | |
download | simplejson-compat.tar.gz |
Simplify compatibility code.compat
Since minimal supported Python 3 version is 3.3, the u() helper
no longer needed.
Diffstat (limited to 'simplejson/tests/test_dump.py')
-rw-r--r-- | simplejson/tests/test_dump.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/simplejson/tests/test_dump.py b/simplejson/tests/test_dump.py index f5f4c1f..2a30125 100644 --- a/simplejson/tests/test_dump.py +++ b/simplejson/tests/test_dump.py @@ -1,5 +1,5 @@ from unittest import TestCase -from simplejson.compat import StringIO, long_type, b, binary_type, text_type, PY3 +from simplejson.compat import StringIO, long_type, b, text_type, PY3 import simplejson as json class MisbehavingTextSubtype(text_type): @@ -7,7 +7,7 @@ class MisbehavingTextSubtype(text_type): return "FAIL!" def as_text_type(s): - if PY3 and isinstance(s, binary_type): + if PY3 and isinstance(s, bytes): return s.decode('ascii') return s |