Fix tests for Python 3.

This commit is contained in:
Michael Elsdörfer 2016-08-30 13:20:42 +02:00
parent 4496ea91bd
commit 3681c5c7bf
2 changed files with 3 additions and 3 deletions

View File

@ -31,4 +31,4 @@ def test_lacks_support(bctype, supports_b):
with pytest.raises(BarcodeTypeError):
instance.barcode('test', bctype)
assert instance.output == ''
assert instance.output == b''

View File

@ -19,7 +19,7 @@ def test_function_text_dies_ist_ein_test_lf():
"""test the text printing function with simple string and compare output"""
instance = Dummy()
instance.text('Dies ist ein Test.\n')
assert instance.output == 'Dies ist ein Test.\n'
assert instance.output == b'Dies ist ein Test.\n'
def test_block_text():
@ -27,4 +27,4 @@ def test_block_text():
printer.block_text(
"All the presidents men were eating falafel for breakfast.", font='a')
assert printer.output == \
'All the presidents men were eating falafel\nfor breakfast.'
b'All the presidents men were eating falafel\nfor breakfast.'