On Tue, Jul 16, 2024 at 01:26:07PM +0200, Thomas Huth wrote:
> Integrate the new python-based test framework with the meson build
> system. Since these tests now require the pycotap module, make
> sure that it gets installed in the venv.
> 
> The changes to the meson.build files are partly based on an earlier
> patch by Ani Sinha (but heavily modified by Thomas Huth e.g. to use
> pycotap for running the tests instead).
> 
> Signed-off-by: Thomas Huth <th...@redhat.com>
> ---
>  pythondeps.toml              |  3 +-
>  tests/Makefile.include       | 18 ++++++++-
>  tests/functional/meson.build | 75 ++++++++++++++++++++++++++++++++++++
>  tests/meson.build            |  1 +
>  4 files changed, 95 insertions(+), 2 deletions(-)
>  create mode 100644 tests/functional/meson.build

Strictly speaking this patch probably ought to be #2, otherwise we
have a bisection window where we've converted some tests but not
run them.

> 
> diff --git a/pythondeps.toml b/pythondeps.toml
> index f6e590fdd8..c018b4d74a 100644
> --- a/pythondeps.toml
> +++ b/pythondeps.toml
> @@ -26,9 +26,10 @@ meson = { accepted = ">=1.1.0", installed = "1.2.3", 
> canary = "meson" }
>  sphinx = { accepted = ">=3.4.3", installed = "5.3.0", canary = 
> "sphinx-build" }
>  sphinx_rtd_theme = { accepted = ">=0.5", installed = "1.1.1" }
>  
> -[avocado]
> +[tests]
>  # Note that qemu.git/python/ is always implicitly installed.
>  # Prefer an LTS version when updating the accepted versions of
>  # avocado-framework, for example right now the limit is 92.x.
>  avocado-framework = { accepted = "(>=88.1, <93.0)", installed = "88.1", 
> canary = "avocado" }
>  pycdlib = { accepted = ">=1.11.0" }
> +pycotap = { accepted = ">=1.1.0" }
> diff --git a/tests/Makefile.include b/tests/Makefile.include
> index d39d5dd6a4..2bdf607977 100644
> --- a/tests/Makefile.include
> +++ b/tests/Makefile.include
> @@ -9,6 +9,8 @@ check-help:
>       @echo "Individual test suites:"
>       @echo " $(MAKE) check-qtest-TARGET     Run qtest tests for given target"
>       @echo " $(MAKE) check-qtest            Run qtest tests"
> +     @echo " $(MAKE) check-functional       Run python-based functional 
> tests"
> +     @echo " $(MAKE) check-functional-TARG  Run functional tests for a given 
> target"

We could increase whitespace by 2 to fit TARGET, or shorten all
cases to TGT ?

>       @echo " $(MAKE) check-unit             Run qobject tests"
>       @echo " $(MAKE) check-qapi-schema      Run QAPI schema tests"
>       @echo " $(MAKE) check-block            Run block tests"
> @@ -111,7 +113,7 @@ quiet-venv-pip = $(quiet-@)$(call quiet-command-run, \
>  

The above is a minor non-functional point though so

Reviewed-by: Daniel P. Berrangé <berra...@redhat.com>


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 via email to