Use bytes for python3 friendly os.write
Bytes not str. Otherwise we get TypeError: a bytes-like object is required, not 'str' in the metadata proxy and it dies. Closes-Bug: #1661303 Change-Id: If6b6f19130c965436a637a03a4cf72203e0786b0
This commit is contained in:
@@ -181,7 +181,7 @@ class TestPidfile(base.BaseTestCase):
|
||||
|
||||
self.os.assert_has_calls([
|
||||
mock.call.ftruncate(FAKE_FD, 0),
|
||||
mock.call.write(FAKE_FD, '34'),
|
||||
mock.call.write(FAKE_FD, b'34'),
|
||||
mock.call.fsync(FAKE_FD)]
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user