From: "Alex Bennée" <alex.bennee@linaro.org>
To: qemu-devel@nongnu.org
Cc: "Alex Bennée" <alex.bennee@linaro.org>
Subject: [PATCH] tests/functional: skip vulkan tests when not configured
Date: Sun, 9 Mar 2025 17:19:08 +0000 [thread overview]
Message-ID: <20250309171908.3087067-1-alex.bennee@linaro.org> (raw)
The CI images don't have the vulkan drivers for the non-existent
hardware even if they can't see the DRI devices. Skip the test early
in this case. While at it fix the missing logging which doesn't seem
to like f-strings.
Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
---
tests/functional/test_aarch64_virt_gpu.py | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
diff --git a/tests/functional/test_aarch64_virt_gpu.py b/tests/functional/test_aarch64_virt_gpu.py
index c6f7738e93..f19a47f8b6 100755
--- a/tests/functional/test_aarch64_virt_gpu.py
+++ b/tests/functional/test_aarch64_virt_gpu.py
@@ -18,7 +18,7 @@
from qemu_test.linuxkernel import LinuxKernelTest
from re import search
-from subprocess import check_output
+from subprocess import check_output, CalledProcessError
class Aarch64VirtGPUMachine(LinuxKernelTest):
@@ -75,7 +75,7 @@ def _launch_virt_gpu(self, gpu_device):
elif "'type' does not accept value 'egl-headless'" in excp.output:
self.skipTest("egl-headless support is not available")
else:
- self.log.info(f"unhandled launch failure: {excp.output}")
+ self.log.info("unhandled launch failure: %s", excp.output)
raise excp
self.wait_for_console_pattern('buildroot login:')
@@ -119,7 +119,11 @@ def test_aarch64_virt_with_vulkan_gpu(self):
self.require_device('virtio-gpu-gl-pci')
- vk_info = check_output(["vulkaninfo", "--summary"], encoding="utf-8")
+ try:
+ vk_info = check_output(["vulkaninfo", "--summary"],
+ encoding="utf-8")
+ except CalledProcessError as excp:
+ self.skipTest(f"Miss-configured host Vulkan: {excp.output}")
if search(r"driverID\s+=\s+DRIVER_ID_NVIDIA_PROPRIETARY", vk_info):
self.skipTest("Test skipped on NVIDIA proprietary driver")
--
2.39.5
reply other threads:[~2025-03-09 17:21 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20250309171908.3087067-1-alex.bennee@linaro.org \
--to=alex.bennee@linaro.org \
--cc=qemu-devel@nongnu.org \
/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).