1
0
mirror of https://github.com/django/django.git synced 2025-10-23 21:59:11 +00:00

Refs #23919 -- Removed default 'utf-8' argument for str.encode()/decode().

This commit is contained in:
Tim Graham
2017-02-07 12:05:47 -05:00
parent 21f13ff5b3
commit 500532c95d
32 changed files with 61 additions and 65 deletions

View File

@@ -214,7 +214,7 @@ class TestUtilsText(SimpleTestCase):
def test_compress_sequence(self):
data = [{'key': i} for i in range(10)]
seq = list(json.JSONEncoder().iterencode(data))
seq = [s.encode('utf-8') for s in seq]
seq = [s.encode() for s in seq]
actual_length = len(b''.join(seq))
out = text.compress_sequence(seq)
compressed_length = len(b''.join(out))