Commit e0fd20ee authored by Stefan Behnel's avatar Stefan Behnel

cleanup

parent 0ed84521
...@@ -3,19 +3,21 @@ ...@@ -3,19 +3,21 @@
import sys import sys
if sys.version_info[0] < 3: if sys.version_info[0] < 3:
__doc__ = u""" __doc__ = u"""
>>> expected = b''.join([chr(i) for i in range(0x10,0xFF,0x11)] + [chr(0xFF)])
>>> s = test_assign() >>> s = test_assign()
>>> assert s == b''.join([chr(i) for i in range(0x10,0xFF,0x11)] + [chr(0xFF)]), repr(s) >>> assert s == expected, repr(s)
>>> s = test_array() >>> s = test_array()
>>> assert s == b''.join([chr(i) for i in range(0x10,0xFF,0x11)] + [chr(0xFF)]), repr(s) >>> assert s == expected, repr(s)
""" """
else: else:
__doc__ = u""" __doc__ = u"""
>>> s = test_assign() >>> s = test_assign()
>>> assert s == bytes([i for i in range(0x10,0xFF,0x11)] + [0xFF]), repr(s) >>> assert s == bytes(list(range(0x10,0xFF,0x11)) + [0xFF]), repr(s)
>>> s = test_array() >>> s = test_array()
>>> assert s == bytes([i for i in range(0x10,0xFF,0x11)] + [0xFF]), repr(s) >>> assert s == bytes(list(range(0x10,0xFF,0x11)) + [0xFF]), repr(s)
""" """
def test_assign(): def test_assign():
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment