Fixing one more bytes vs string battle in Python 3

This commit is contained in:
Christopher Allan Webber 2016-02-11 11:36:05 -08:00
parent 64b989a756
commit cd4a7492cd

View File

@ -69,7 +69,7 @@ class TestWorkbench(object):
filepath = ['dir1', 'dir2', 'ourfile.txt'] filepath = ['dir1', 'dir2', 'ourfile.txt']
with this_storage.get_file(filepath, 'w') as our_file: with this_storage.get_file(filepath, 'w') as our_file:
our_file.write('Our file') our_file.write(b'Our file')
# with a local file storage # with a local file storage
filename = this_workbench.localized_file(this_storage, filepath) filename = this_workbench.localized_file(this_storage, filepath)
@ -83,7 +83,7 @@ class TestWorkbench(object):
# ... write a brand new file, again ;) # ... write a brand new file, again ;)
with this_storage.get_file(filepath, 'w') as our_file: with this_storage.get_file(filepath, 'w') as our_file:
our_file.write('Our file') our_file.write(b'Our file')
filename = this_workbench.localized_file(this_storage, filepath) filename = this_workbench.localized_file(this_storage, filepath)
assert filename == os.path.join( assert filename == os.path.join(