tests: fix handling TestProcess.communicate(None)

This commit is contained in:
Marek Marczykowski-Górecki 2017-05-25 16:08:00 +02:00
parent fe51e8862a
commit c435de06a1
No known key found for this signature in database
GPG Key ID: 063938BA42CFA724

View File

@ -65,7 +65,8 @@ class TestProcess(object):
self.returncode = 0
def communicate(self, input=None):
self.stdin.write(input)
if input is not None:
self.stdin.write(input)
self.stdin.close()
self.stdin_close()
return self.stdout, self.stderr