All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Daniel P. Berrangé" <berrange@redhat.com>
To: "Alex Bennée" <alex.bennee@linaro.org>
Cc: qemu-devel@nongnu.org, qemu-arm@nongnu.org,
	"Peter Maydell" <peter.maydell@linaro.org>,
	"Kyle Evans" <kevans@freebsd.org>,
	"Eduardo Habkost" <eduardo@habkost.net>,
	"Alexandre Iooss" <erdnaxe@crans.org>,
	"Marc-André Lureau" <marcandre.lureau@redhat.com>,
	"Laurent Vivier" <laurent@vivier.eu>,
	"Mahmoud Mandour" <ma.mandourr@gmail.com>,
	"Paolo Bonzini" <pbonzini@redhat.com>,
	"Li-Wen Hsu" <lwhsu@freebsd.org>,
	"Riku Voipio" <riku.voipio@iki.fi>,
	"Warner Losh" <imp@bsdimp.com>,
	"Pierrick Bouvier" <pierrick.bouvier@linaro.org>,
	"Philippe Mathieu-Daudé" <philmd@linaro.org>,
	"Richard Henderson" <richard.henderson@linaro.org>,
	"Ed Maste" <emaste@freebsd.org>, "Thomas Huth" <thuth@redhat.com>
Subject: Re: [PATCH 07/25] tests/functional: Allow running TCG plugins tests on non-Linux/BSD hosts
Date: Thu, 27 Feb 2025 09:03:15 +0000	[thread overview]
Message-ID: <Z8AqU7HaD9kraz_c@redhat.com> (raw)
In-Reply-To: <20250226140343.3907080-8-alex.bennee@linaro.org>

On Wed, Feb 26, 2025 at 02:03:25PM +0000, Alex Bennée wrote:
> From: Philippe Mathieu-Daudé <philmd@linaro.org>
> 
> Not all platforms use the '.so' suffix for shared libraries,
> which is how plugins are built. Use the recently introduced
> dso_suffix() helper to get the proper host suffix.
> 
> Resolves: https://gitlab.com/qemu-project/qemu/-/issues/2804
> Suggested-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
> Suggested-by: Daniel P. Berrangé <berrange@redhat.com>
> Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
> Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
> Reviewed-by: Thomas Huth <thuth@redhat.com>
> Message-Id: <20250220080215.49165-4-philmd@linaro.org>
> Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
> ---
>  tests/functional/test_aarch64_tcg_plugins.py | 11 ++++++++---
>  1 file changed, 8 insertions(+), 3 deletions(-)
> 
> diff --git a/tests/functional/test_aarch64_tcg_plugins.py b/tests/functional/test_aarch64_tcg_plugins.py
> index 7e8beacc83..5736b60545 100755
> --- a/tests/functional/test_aarch64_tcg_plugins.py
> +++ b/tests/functional/test_aarch64_tcg_plugins.py
> @@ -13,10 +13,11 @@
>  
>  import tempfile
>  import mmap
> +import os
>  import re
>  
>  from qemu.machine.machine import VMLaunchFailure
> -from qemu_test import LinuxKernelTest, Asset
> +from qemu_test import LinuxKernelTest, Asset, dso_suffix
>  
>  
>  class PluginKernelBase(LinuxKernelTest):
> @@ -62,6 +63,10 @@ class PluginKernelNormal(PluginKernelBase):
>          ('https://storage.tuxboot.com/20230331/arm64/Image'),
>          'ce95a7101a5fecebe0fe630deee6bd97b32ba41bc8754090e9ad8961ea8674c7')
>  
> +    def plugin_file(self, plugin_name):
> +        sfx = dso_suffix()
> +        return os.path.join('tests', 'tcg', 'plugins', f'{plugin_name}.{sfx}')

General purpose helper functions shouldn't go in the test cases files.
This it better placed in tests/functional/qemu_test/testcase.py, alongside
all the other path construction helper functions.


With regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|

  reply	other threads:[~2025-02-27  9:03 UTC|newest]

Thread overview: 48+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-26 14:03 [PATCH 00/25] maintainer updates for 10.0 softfreeze (gpu/tcg tests, plugins, MAINTAINERS) Alex Bennée
2025-02-26 14:03 ` [PATCH 01/25] tests/functional: move aarch64 GPU test into own file Alex Bennée
2025-02-26 15:27   ` Thomas Huth
2025-02-26 17:19   ` Richard Henderson
2025-02-26 18:08     ` Alex Bennée
2025-02-26 14:03 ` [PATCH 02/25] tests/functional: factor out common code in gpu test Alex Bennée
2025-02-26 15:32   ` Thomas Huth
2025-02-26 14:03 ` [PATCH 03/25] tests/functional: ensure we have a GPU device for tests Alex Bennée
2025-02-26 15:59   ` Thomas Huth
2025-02-26 14:03 ` [PATCH 04/25] tests/functional: expand tests to cover virgl Alex Bennée
2025-02-26 16:03   ` Thomas Huth
2025-02-26 14:03 ` [PATCH 05/25] plugins: add explicit dependency in functional tests Alex Bennée
2025-02-26 14:03 ` [PATCH 06/25] tests/functional: Introduce the dso_suffix() helper Alex Bennée
2025-02-26 14:03 ` [PATCH 07/25] tests/functional: Allow running TCG plugins tests on non-Linux/BSD hosts Alex Bennée
2025-02-27  9:03   ` Daniel P. Berrangé [this message]
2025-02-26 14:03 ` [PATCH 08/25] tests/functional: skip vulkan tests with nVidia Alex Bennée
2025-02-26 16:07   ` Thomas Huth
2025-02-26 14:03 ` [PATCH 09/25] libvirt-ci: bump to latest for vulkan-tools (libvirt MR 525) Alex Bennée
2025-02-26 16:14   ` Thomas Huth
2025-02-26 14:03 ` [PATCH 10/25] tests/vm: bump timeout for shutdown Alex Bennée
2025-02-26 16:15   ` Thomas Huth
2025-02-26 14:03 ` [PATCH 11/25] tests/tcg: mark test-vma as a linux-only test Alex Bennée
2025-02-26 16:16   ` Thomas Huth
2025-02-26 14:03 ` [PATCH 12/25] tests/tcg: add message to _Static_assert in test-avx Alex Bennée
2025-02-26 16:17   ` Thomas Huth
2025-02-26 14:03 ` [PATCH 13/25] tests/tcg: fix constraints in test-i386-adcox Alex Bennée
2025-02-26 17:26   ` Richard Henderson
2025-02-28 11:35     ` Alex Bennée
2025-02-28 17:35       ` Richard Henderson
2025-02-26 14:03 ` [PATCH 14/25] tests/tcg: enable -fwrapv for test-i386-bmi Alex Bennée
2025-02-26 17:27   ` Richard Henderson
2025-02-26 14:03 ` [PATCH 15/25] plugins/api: use qemu_target_page_mask() to get value Alex Bennée
2025-02-26 17:27   ` Richard Henderson
2025-02-26 22:19   ` Philippe Mathieu-Daudé
2025-02-26 14:03 ` [PATCH 16/25] plugins/loader: populate target_name with target_name() Alex Bennée
2025-02-26 14:03 ` [PATCH 17/25] include/qemu: plugin-memory.h doesn't need cpu-defs.h Alex Bennée
2025-02-26 14:03 ` [PATCH 18/25] plugins/api: clean-up the includes Alex Bennée
2025-02-26 14:03 ` [PATCH 19/25] plugins/plugin.h: include queue.h Alex Bennée
2025-02-26 14:03 ` [PATCH 20/25] plugins/loader: compile loader only once Alex Bennée
2025-02-26 14:03 ` [PATCH 21/25] plugins/api: split out binary path/start/end/entry code Alex Bennée
2025-02-26 15:28   ` Warner Losh
2025-02-26 17:29   ` Richard Henderson
2025-02-26 14:03 ` [PATCH 22/25] plugins/api: split out the vaddr/hwaddr helpers Alex Bennée
2025-02-26 14:03 ` [PATCH 23/25] plugins/api: split out time control helpers Alex Bennée
2025-02-26 14:03 ` [PATCH 24/25] plugins/api: build only once Alex Bennée
2025-02-26 14:03 ` [PATCH 25/25] MAINTAINERS: remove widely sanctioned entities Alex Bennée
2025-02-27 15:45   ` Daniel Henrique Barboza
2025-02-28 10:39     ` Alex Bennée

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=Z8AqU7HaD9kraz_c@redhat.com \
    --to=berrange@redhat.com \
    --cc=alex.bennee@linaro.org \
    --cc=eduardo@habkost.net \
    --cc=emaste@freebsd.org \
    --cc=erdnaxe@crans.org \
    --cc=imp@bsdimp.com \
    --cc=kevans@freebsd.org \
    --cc=laurent@vivier.eu \
    --cc=lwhsu@freebsd.org \
    --cc=ma.mandourr@gmail.com \
    --cc=marcandre.lureau@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=peter.maydell@linaro.org \
    --cc=philmd@linaro.org \
    --cc=pierrick.bouvier@linaro.org \
    --cc=qemu-arm@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=richard.henderson@linaro.org \
    --cc=riku.voipio@iki.fi \
    --cc=thuth@redhat.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.