aboutsummaryrefslogtreecommitdiff
path: root/tests/qemu-iotests
diff options
context:
space:
mode:
authorMax Reitz <mreitz@redhat.com>2018-10-22 14:53:00 +0100
committerEduardo Habkost <ehabkost@redhat.com>2018-10-30 21:11:52 -0300
commitf544adf736cb1b100a7fe926f3712157b22c3ddd (patch)
treef678846bb8bdc5360f4fec2524f800bc2d7cabff /tests/qemu-iotests
parent6d39db96d23ebe0d4361d108fa202091aa9cbfc1 (diff)
iotests: Flush in iotests.py's QemuIoInteractive
After issuing a command, flush the pipe. This does not change anything in Python 2, but it makes a difference in Python 3. Signed-off-by: Max Reitz <mreitz@redhat.com> Reviewed-by: Eduardo Habkost <ehabkost@redhat.com> Reviewed-by: Cleber Rosa <crosa@redhat.com> Message-Id: <20181022135307.14398-3-mreitz@redhat.com> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
Diffstat (limited to 'tests/qemu-iotests')
-rw-r--r--tests/qemu-iotests/iotests.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/tests/qemu-iotests/iotests.py b/tests/qemu-iotests/iotests.py
index 4e67fbbe96..10f2d17419 100644
--- a/tests/qemu-iotests/iotests.py
+++ b/tests/qemu-iotests/iotests.py
@@ -178,6 +178,7 @@ class QemuIoInteractive:
cmd = cmd.strip()
assert cmd != 'q' and cmd != 'quit'
self._p.stdin.write(cmd + '\n')
+ self._p.stdin.flush()
return self._read_output()