diff options
Diffstat (limited to 'Lib/test/test_struct.py')
-rw-r--r-- | Lib/test/test_struct.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/test/test_struct.py b/Lib/test/test_struct.py index 83d7efb..cc6db32 100644 --- a/Lib/test/test_struct.py +++ b/Lib/test/test_struct.py @@ -674,8 +674,8 @@ def test_bool(): elif not prefix and verbose: print('size of bool in native format is %i' % (len(packed))) - for c in str8('\x01\x7f\xff\x0f\xf0'): - if struct.unpack('>t', c)[0] is not True: + for c in b'\x01\x7f\xff\x0f\xf0': + if struct.unpack('>t', bytes([c]))[0] is not True: raise TestFailed('%c did not unpack as True' % c) test_bool() |