qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Philippe Mathieu-Daudé" <f4bug@amsat.org>
To: qemu-devel@nongnu.org
Cc: "Peter Maydell" <peter.maydell@linaro.org>,
	"Eduardo Habkost" <ehabkost@redhat.com>,
	"Alistair Francis" <alistair@alistair23.me>,
	"Caio Carrara" <ccarrara@redhat.com>,
	"Subbaraya Sundeep" <sundeep.lkml@gmail.com>,
	qemu-arm@nongnu.org, "Cleber Rosa" <crosa@redhat.com>,
	"Philippe Mathieu-Daudé" <f4bug@amsat.org>
Subject: [Qemu-devel] [PATCH 1/2] BootLinuxConsoleTest: Do not log empty lines
Date: Tue, 21 May 2019 00:06:34 +0200	[thread overview]
Message-ID: <20190520220635.10961-2-f4bug@amsat.org> (raw)
In-Reply-To: <20190520220635.10961-1-f4bug@amsat.org>

Avoid to log empty lines in console debug logs.

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
 tests/acceptance/boot_linux_console.py | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/tests/acceptance/boot_linux_console.py b/tests/acceptance/boot_linux_console.py
index d5c500ea30..f593f3858e 100644
--- a/tests/acceptance/boot_linux_console.py
+++ b/tests/acceptance/boot_linux_console.py
@@ -37,8 +37,10 @@ class BootLinuxConsole(Test):
         console = self.vm.console_socket.makefile()
         console_logger = logging.getLogger('console')
         while True:
-            msg = console.readline()
-            console_logger.debug(msg.strip())
+            msg = console.readline().strip()
+            if not msg:
+                continue
+            console_logger.debug(msg)
             if success_message in msg:
                 break
             if failure_message in msg:
-- 
2.19.1



  reply	other threads:[~2019-05-20 22:08 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-20 22:06 [Qemu-devel] [PATCH 0/2] tests: Avocado-test for the SmartFusion2 board Philippe Mathieu-Daudé
2019-05-20 22:06 ` Philippe Mathieu-Daudé [this message]
2019-05-20 22:34   ` [Qemu-devel] [PATCH 1/2] BootLinuxConsoleTest: Do not log empty lines Alistair Francis
2019-05-23 13:48   ` Cleber Rosa
2019-06-05 15:57   ` Cleber Rosa
2019-06-05 20:52   ` Aleksandar Markovic
2019-05-20 22:06 ` [Qemu-devel] [PATCH 2/2] BootLinuxConsoleTest: Test the SmartFusion2 board Philippe Mathieu-Daudé
2019-05-20 22:35   ` Alistair Francis
2019-05-23 14:07   ` Cleber Rosa
2019-06-05 16:06   ` Cleber Rosa
2019-06-05 20:43     ` Eduardo Habkost
2019-06-06 18:29       ` Cleber Rosa

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190520220635.10961-2-f4bug@amsat.org \
    --to=f4bug@amsat.org \
    --cc=alistair@alistair23.me \
    --cc=ccarrara@redhat.com \
    --cc=crosa@redhat.com \
    --cc=ehabkost@redhat.com \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-arm@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=sundeep.lkml@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).