diff options
author | Ask Solem <ask@celeryproject.org> | 2017-02-16 10:44:48 -0800 |
---|---|---|
committer | Ask Solem <ask@celeryproject.org> | 2017-02-16 10:44:48 -0800 |
commit | e6fab2f68b562cf1400bd8167e9b755f0482aafe (patch) | |
tree | b4d6be32dc8c62fa032e3c1a1a74636ac8360a38 /t/unit/utils/test_encoding.py | |
parent | f2f7c67651106e77fb2db60ded134404ccc0a626 (diff) | |
download | kombu-5.0-devel.tar.gz |
WIP5.0-devel
Diffstat (limited to 't/unit/utils/test_encoding.py')
-rw-r--r-- | t/unit/utils/test_encoding.py | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/t/unit/utils/test_encoding.py b/t/unit/utils/test_encoding.py index e3d1040a..bff3a321 100644 --- a/t/unit/utils/test_encoding.py +++ b/t/unit/utils/test_encoding.py @@ -1,13 +1,7 @@ # -*- coding: utf-8 -*- -from __future__ import absolute_import, unicode_literals - import sys - from contextlib import contextmanager - from case import patch, skip - -from kombu.five import bytes_t, string_t from kombu.utils.encoding import ( get_default_encoding_file, safe_str, set_default_encoding_file, default_encoding, @@ -50,13 +44,13 @@ class test_default_encoding: @skip.if_python3() def test_str_to_bytes(): with clean_encoding() as e: - assert isinstance(e.str_to_bytes('foobar'), bytes_t) + assert isinstance(e.str_to_bytes('foobar'), bytes) @skip.if_python3() def test_from_utf8(): with clean_encoding() as e: - assert isinstance(e.from_utf8('foobar'), bytes_t) + assert isinstance(e.from_utf8('foobar'), bytes) @skip.if_python3() @@ -75,7 +69,7 @@ class test_safe_str: assert safe_str('foo') == 'foo' def test_when_unicode(self): - assert isinstance(safe_str('foo'), string_t) + assert isinstance(safe_str('foo'), str) def test_when_encoding_utf8(self): self._encoding.return_value = 'utf-8' |