This logs the command as a single blog with properly escaped line breaks, which allows copy+pasting the command. Helps for manually reproducing a test.
Signed-off-by: Cole Robinson <[email protected]> --- virttest/qemu_vm.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/virttest/qemu_vm.py b/virttest/qemu_vm.py index 0250efb..3ba2ce5 100644 --- a/virttest/qemu_vm.py +++ b/virttest/qemu_vm.py @@ -1785,9 +1785,8 @@ class VM(virt_vm.BaseVM): logging.info, "[9p proxy helper]") - logging.info("Running qemu command (reformatted):") - for item in qemu_command.replace(" -", " \n -").splitlines(): - logging.info("%s", item) + logging.info("Running qemu command (reformatted):\n%s", + qemu_command.replace(" -", " \\\n -")) self.qemu_command = qemu_command self.process = aexpect.run_bg(qemu_command, None, logging.info, "[qemu output] ") -- 1.8.1.4 _______________________________________________ Virt-test-devel mailing list [email protected] https://www.redhat.com/mailman/listinfo/virt-test-devel
