[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 12/28] tests/functional: logs details of console interaction opera
From: |
Alex Bennée |
Subject: |
[PULL 12/28] tests/functional: logs details of console interaction operations |
Date: |
Mon, 25 Nov 2024 15:20:49 +0000 |
From: Daniel P. Berrangé <berrange@redhat.com>
When functional tests go wrong, it will often be related to the console
interaction wait state. By logging the messages that we're looking for,
and data we're about to be sending, it'll be easier to diagnose where
tests are getting stuck.
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20241121154218.1423005-13-berrange@redhat.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
Message-Id: <20241121165806.476008-13-alex.bennee@linaro.org>
diff --git a/tests/functional/qemu_test/cmd.py
b/tests/functional/qemu_test/cmd.py
index cbabb1ceed..98722a9cf6 100644
--- a/tests/functional/qemu_test/cmd.py
+++ b/tests/functional/qemu_test/cmd.py
@@ -85,6 +85,9 @@ def _console_interaction(test, success_message,
failure_message,
vm = test.vm
console = vm.console_file
console_logger = logging.getLogger('console')
+ test.log.debug(
+ f"Console interaction: success_msg='{success_message}' " +
+ f"failure_msg='{failure_message}' send_string='{send_string}'")
while True:
if send_string:
vm.console_socket.sendall(send_string.encode())
--
2.39.5
- [PULL 01/28] tests/functional: fix mips64el test to honour workdir, (continued)
- [PULL 01/28] tests/functional: fix mips64el test to honour workdir, Alex Bennée, 2024/11/25
- [PULL 03/28] tests/functional: remove "AVOCADO" from env variable name, Alex Bennée, 2024/11/25
- [PULL 02/28] tests/functional: automatically clean up scratch files after tests, Alex Bennée, 2024/11/25
- [PULL 04/28] tests/functional: remove todo wrt avocado.utils.wait_for, Alex Bennée, 2024/11/25
- [PULL 07/28] tests/functional: remove comments talking about avocado, Alex Bennée, 2024/11/25
- [PULL 11/28] tests/functional: enable debug logging for QEMUMachine, Alex Bennée, 2024/11/25
- [PULL 10/28] tests/functional: honour requested test VM name in QEMUMachine, Alex Bennée, 2024/11/25
- [PULL 05/28] tests/functional: remove leftover :avocado: tags, Alex Bennée, 2024/11/25
- [PULL 09/28] tests/functional: put QEMUMachine logs in testcase log directory, Alex Bennée, 2024/11/25
- [PULL 12/28] tests/functional: logs details of console interaction operations,
Alex Bennée <=
- [PULL 06/28] tests/functional: remove obsolete reference to avocado bug, Alex Bennée, 2024/11/25
- [PULL 24/28] rust/pl011: Fix range checks for device ID accesses, Alex Bennée, 2024/11/25
- [PULL 08/28] tests/functional: honour self.workdir in ACPI bits tests, Alex Bennée, 2024/11/25
- [PULL 16/28] tests/functional: remove time.sleep usage from tuxrun tests, Alex Bennée, 2024/11/25
- [PULL 26/28] tests/functional: Convert Aspeed aarch64 SDK tests, Alex Bennée, 2024/11/25
- [PULL 14/28] tests/functional: require non-NULL success_message for console wait, Alex Bennée, 2024/11/25
- [PULL 28/28] tests/functional: Remove sleep workarounds from Aspeed tests, Alex Bennée, 2024/11/25
- [PULL 13/28] tests/functional: don't try to wait for the empty string, Alex Bennée, 2024/11/25
- [PULL 15/28] tests/functional: rewrite console handling to be bytewise, Alex Bennée, 2024/11/25