* [PATCH v4 0/4] Python: drop avocado, formally support python3.14
@ 2026-02-26 21:33 John Snow
2026-02-26 21:33 ` [PATCH v4 1/4] python: pin 'wheel' version in minreqs test John Snow
` (3 more replies)
0 siblings, 4 replies; 7+ messages in thread
From: John Snow @ 2026-02-26 21:33 UTC (permalink / raw)
To: qemu-devel
Cc: Alex Bennée, Cleber Rosa, John Snow, Thomas Huth,
Paolo Bonzini
This patchset drops avocado for the python tests, which fixes the
optional python-check-tox GitLab CI test, and adds formal testing and
support for Python3.14 to QEMU.
v4:
- Rebased
- Adjusted phrasing in 2/4 to reflect that this is a stopgap on the
road to meson test
- Simplified subprocess calls in linters.py
v3:
- Fixed typo in patch 4 ("python 3.14" => "python3.14")
v2:
- Also search for Python3.14 during configure
- Rebase on top of master now that qemu.qmp is dropped
John Snow (4):
python: pin 'wheel' version in minreqs test
python: replace avocado tests with pytest
python: drop avocado
python: add formal python3.14 support and testing
python/README.rst | 2 -
configure | 4 +-
python/Makefile | 6 +--
python/avocado.cfg | 13 ------
python/setup.cfg | 5 ++-
python/tests/flake8.sh | 3 --
python/tests/iotests-mypy.sh | 4 --
python/tests/iotests-pylint.sh | 5 ---
python/tests/isort.sh | 3 --
python/tests/linters.py | 79 ++++++++++++++++++++++++++++++++++
python/tests/minreqs.txt | 3 +-
python/tests/mypy.sh | 3 --
python/tests/pylint.sh | 4 --
python/tests/qapi-flake8.sh | 6 ---
python/tests/qapi-isort.sh | 8 ----
python/tests/qapi-mypy.sh | 4 --
python/tests/qapi-pylint.sh | 8 ----
17 files changed, 88 insertions(+), 72 deletions(-)
delete mode 100644 python/avocado.cfg
delete mode 100755 python/tests/flake8.sh
delete mode 100755 python/tests/iotests-mypy.sh
delete mode 100755 python/tests/iotests-pylint.sh
delete mode 100755 python/tests/isort.sh
create mode 100644 python/tests/linters.py
delete mode 100755 python/tests/mypy.sh
delete mode 100755 python/tests/pylint.sh
delete mode 100755 python/tests/qapi-flake8.sh
delete mode 100755 python/tests/qapi-isort.sh
delete mode 100755 python/tests/qapi-mypy.sh
delete mode 100755 python/tests/qapi-pylint.sh
--
2.53.0
^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCH v4 1/4] python: pin 'wheel' version in minreqs test
2026-02-26 21:33 [PATCH v4 0/4] Python: drop avocado, formally support python3.14 John Snow
@ 2026-02-26 21:33 ` John Snow
2026-02-26 21:33 ` [PATCH v4 2/4] python: replace avocado tests with pytest John Snow
` (2 subsequent siblings)
3 siblings, 0 replies; 7+ messages in thread
From: John Snow @ 2026-02-26 21:33 UTC (permalink / raw)
To: qemu-devel
Cc: Alex Bennée, Cleber Rosa, John Snow, Thomas Huth,
Paolo Bonzini, Daniel P. Berrangé
With recent python packaging ecosystem updates, the latest 'wheel' is no
longer compatible with older packages - and was somehow still compatible
with our Python 3.9 environment. Pin wheel to an older version (Version
based on Debian 11's available wheel package) to remove warnings during
the minreqs test.
Signed-off-by: John Snow <jsnow@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
---
python/Makefile | 2 --
python/tests/minreqs.txt | 1 +
2 files changed, 1 insertion(+), 2 deletions(-)
diff --git a/python/Makefile b/python/Makefile
index 32aedce4137..b6c9cd1bce2 100644
--- a/python/Makefile
+++ b/python/Makefile
@@ -63,8 +63,6 @@ $(QEMU_MINVENV_DIR) $(QEMU_MINVENV_DIR)/bin/activate: setup.cfg tests/minreqs.tx
@( \
echo "ACTIVATE $(QEMU_MINVENV_DIR)"; \
. $(QEMU_MINVENV_DIR)/bin/activate; \
- echo "INSTALL wheel $(QEMU_MINVENV_DIR)"; \
- $(PIP_INSTALL) wheel 1>/dev/null; \
echo "INSTALL -r tests/minreqs.txt $(QEMU_MINVENV_DIR)";\
$(PIP_INSTALL) -r tests/minreqs.txt 1>/dev/null; \
echo "INSTALL -e qemu $(QEMU_MINVENV_DIR)"; \
diff --git a/python/tests/minreqs.txt b/python/tests/minreqs.txt
index 855b5129c94..38b17d17e14 100644
--- a/python/tests/minreqs.txt
+++ b/python/tests/minreqs.txt
@@ -16,6 +16,7 @@
# installation of the QEMU package itself fails, failing to find
# setuptools.
setuptools<=70
+wheel==0.34.2
# Dependencies for qapidoc/qapi_domain et al
sphinx==3.4.3
--
2.53.0
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH v4 2/4] python: replace avocado tests with pytest
2026-02-26 21:33 [PATCH v4 0/4] Python: drop avocado, formally support python3.14 John Snow
2026-02-26 21:33 ` [PATCH v4 1/4] python: pin 'wheel' version in minreqs test John Snow
@ 2026-02-26 21:33 ` John Snow
2026-02-27 8:09 ` Daniel P. Berrangé
2026-02-27 9:34 ` Thomas Huth
2026-02-26 21:33 ` [PATCH v4 3/4] python: drop avocado John Snow
2026-02-26 21:34 ` [PATCH v4 4/4] python: add formal python3.14 support and testing John Snow
3 siblings, 2 replies; 7+ messages in thread
From: John Snow @ 2026-02-26 21:33 UTC (permalink / raw)
To: qemu-devel
Cc: Alex Bennée, Cleber Rosa, John Snow, Thomas Huth,
Paolo Bonzini
Following suit with the rest of this repository, drop avocado and
replace it with the Python standard "pytest" package.
Our ultimate goal is to merge these python tests with the meson test
suite, so the use of 'pytest' here is only a stop-gap solution to get
the GitLab CI 'check-python-tox' passing again following recent Python
packaging ecosystem changes.
Signed-off-by: John Snow <jsnow@redhat.com>
---
python/Makefile | 4 +-
python/setup.cfg | 1 +
python/tests/linters.py | 79 ++++++++++++++++++++++++++++++++++++++++
python/tests/minreqs.txt | 1 +
4 files changed, 83 insertions(+), 2 deletions(-)
create mode 100644 python/tests/linters.py
diff --git a/python/Makefile b/python/Makefile
index b6c9cd1bce2..42994d39618 100644
--- a/python/Makefile
+++ b/python/Makefile
@@ -105,7 +105,7 @@ develop:
.PHONY: check
check:
- @avocado --config avocado.cfg run tests/
+ @pytest -v tests/*.py
.PHONY: check-tox
check-tox:
@@ -113,7 +113,7 @@ check-tox:
.PHONY: check-coverage
check-coverage:
- @coverage run -m avocado --config avocado.cfg run tests/*.py
+ @coverage run -m pytest -v tests/*.py
@coverage combine
@coverage html
@coverage report
diff --git a/python/setup.cfg b/python/setup.cfg
index c46a95f8d41..03344526730 100644
--- a/python/setup.cfg
+++ b/python/setup.cfg
@@ -43,6 +43,7 @@ devel =
mypy >= 1.4.0
pylint >= 2.17.3
pylint != 3.2.4; python_version<"3.9"
+ pytest >= 6.0.2
tox >= 3.18.0
sphinx >= 3.4.3
diff --git a/python/tests/linters.py b/python/tests/linters.py
new file mode 100644
index 00000000000..cce29c0a8ea
--- /dev/null
+++ b/python/tests/linters.py
@@ -0,0 +1,79 @@
+# SPDX-License-Identifier: GPL-2.0-or-later
+
+import os
+from subprocess import check_call
+import sys
+
+
+class TestLinters:
+
+ def test_flake8_pkg(self):
+ check_call([sys.executable, "-m", "flake8", "qemu/"])
+
+ def test_flake8_scripts(self):
+ check_call([sys.executable, "-m", "flake8", "scripts/"])
+
+ def test_flake8_qapi(self):
+ check_call([sys.executable, "-m", "flake8",
+ "../scripts/qapi/",
+ "../docs/sphinx/qapidoc.py",
+ "../docs/sphinx/qapi_domain.py"])
+
+ def test_isort_pkg(self):
+ check_call([sys.executable, "-m", "isort", "-c", "qemu/"])
+
+ def test_isort_scripts(self):
+ check_call([sys.executable, "-m", "isort", "-c", "scripts/"])
+
+ def test_isort_qapi(self):
+ check_call([sys.executable, "-m", "isort",
+ "--sp", ".", "-c", "../scripts/qapi/"])
+
+ def test_isort_qapi_sphinx(self):
+ # Force isort to recognize 'compat' as a local module and not
+ # third-party
+ check_call([sys.executable, "-m", "isort",
+ "--sp", ".", "-c", "-p", "compat",
+ "../docs/sphinx/qapi_domain.py",
+ "../docs/sphinx/qapidoc.py"])
+
+ def test_mypy_pkg(self):
+ check_call([sys.executable, "-m", "mypy", "-p", "qemu"])
+
+ def test_mypy_scripts(self):
+ check_call([sys.executable, "-m", "mypy", "scripts/"])
+
+ def test_mypy_qapi(self):
+ check_call([sys.executable, "-m", "mypy", "../scripts/qapi"])
+
+ def test_mypy_iotests(self):
+ check_call([sys.executable, "-m", "linters", "--mypy"],
+ cwd="../tests/qemu-iotests/")
+
+ # Setuptools v60 introduced the SETUPTOOLS_USE_DISTUTILS=stdlib
+ # workaround; stdlib distutils was fully removed in Python
+ # 3.12+. Once we are on >=3.12+ exclusively, this workaround can be
+ # dropped safely. Until then, it is needed for some versions on
+ # Fedora/Debian distributions which relied upon distro-patched
+ # setuptools present in CPython, but not within setuptools itself.
+
+ def test_pylint_pkg(self):
+ os.environ['SETUPTOOLS_USE_DISTUTILS'] = 'stdlib'
+ check_call([sys.executable, "-m", "pylint", "qemu/"])
+
+ def test_pylint_scripts(self):
+ os.environ['SETUPTOOLS_USE_DISTUTILS'] = 'stdlib'
+ check_call([sys.executable, "-m", "pylint", "scripts/"])
+
+ def test_pylint_qapi(self):
+ os.environ['SETUPTOOLS_USE_DISTUTILS'] = 'stdlib'
+ check_call([sys.executable, "-m", "pylint",
+ "--rcfile=../scripts/qapi/pylintrc",
+ "../scripts/qapi/",
+ "../docs/sphinx/qapidoc.py",
+ "../docs/sphinx/qapi_domain.py"])
+
+ def test_pylint_iotests(self):
+ os.environ['SETUPTOOLS_USE_DISTUTILS'] = 'stdlib'
+ check_call([sys.executable, "-m", "linters", "--pylint"],
+ cwd="../tests/qemu-iotests/")
diff --git a/python/tests/minreqs.txt b/python/tests/minreqs.txt
index 38b17d17e14..19912027076 100644
--- a/python/tests/minreqs.txt
+++ b/python/tests/minreqs.txt
@@ -32,6 +32,7 @@ fusepy==2.0.4
# Test-runners, utilities, etc.
avocado-framework==90.0
+pytest==6.0.2
# Linters
flake8==5.0.4
--
2.53.0
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH v4 3/4] python: drop avocado
2026-02-26 21:33 [PATCH v4 0/4] Python: drop avocado, formally support python3.14 John Snow
2026-02-26 21:33 ` [PATCH v4 1/4] python: pin 'wheel' version in minreqs test John Snow
2026-02-26 21:33 ` [PATCH v4 2/4] python: replace avocado tests with pytest John Snow
@ 2026-02-26 21:33 ` John Snow
2026-02-26 21:34 ` [PATCH v4 4/4] python: add formal python3.14 support and testing John Snow
3 siblings, 0 replies; 7+ messages in thread
From: John Snow @ 2026-02-26 21:33 UTC (permalink / raw)
To: qemu-devel
Cc: Alex Bennée, Cleber Rosa, John Snow, Thomas Huth,
Paolo Bonzini, Daniel P. Berrangé
Avocado-framework is no longer used for anything, so it can be removed.
Signed-off-by: John Snow <jsnow@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
---
python/README.rst | 2 --
python/avocado.cfg | 13 -------------
python/setup.cfg | 1 -
python/tests/flake8.sh | 3 ---
python/tests/iotests-mypy.sh | 4 ----
python/tests/iotests-pylint.sh | 5 -----
python/tests/isort.sh | 3 ---
python/tests/minreqs.txt | 1 -
python/tests/mypy.sh | 3 ---
python/tests/pylint.sh | 4 ----
python/tests/qapi-flake8.sh | 6 ------
python/tests/qapi-isort.sh | 8 --------
python/tests/qapi-mypy.sh | 4 ----
python/tests/qapi-pylint.sh | 8 --------
14 files changed, 65 deletions(-)
delete mode 100644 python/avocado.cfg
delete mode 100755 python/tests/flake8.sh
delete mode 100755 python/tests/iotests-mypy.sh
delete mode 100755 python/tests/iotests-pylint.sh
delete mode 100755 python/tests/isort.sh
delete mode 100755 python/tests/mypy.sh
delete mode 100755 python/tests/pylint.sh
delete mode 100755 python/tests/qapi-flake8.sh
delete mode 100755 python/tests/qapi-isort.sh
delete mode 100755 python/tests/qapi-mypy.sh
delete mode 100755 python/tests/qapi-pylint.sh
diff --git a/python/README.rst b/python/README.rst
index ec5cb5e971b..e34d1a1c7b1 100644
--- a/python/README.rst
+++ b/python/README.rst
@@ -108,8 +108,6 @@ Files in this directory
- ``qemu/`` Python 'qemu' namespace package source directory.
- ``tests/`` Python package tests directory.
-- ``avocado.cfg`` Configuration for the Avocado test-runner.
- Used by ``make check`` et al.
- ``Makefile`` provides some common testing/installation invocations.
Try ``make help`` to see available targets.
- ``MANIFEST.in`` is read by python setuptools, it specifies additional files
diff --git a/python/avocado.cfg b/python/avocado.cfg
deleted file mode 100644
index a4604200594..00000000000
--- a/python/avocado.cfg
+++ /dev/null
@@ -1,13 +0,0 @@
-[run]
-test_runner = nrunner
-
-[simpletests]
-# Don't show stdout/stderr in the test *summary*
-status.failure_fields = ['status']
-
-[job]
-# Don't show the full debug.log output; only select stdout/stderr.
-output.testlogs.logfiles = ['stdout', 'stderr']
-
-# Show full stdout/stderr only on tests that FAIL
-output.testlogs.statuses = ['FAIL']
diff --git a/python/setup.cfg b/python/setup.cfg
index 03344526730..e5bf498f0e1 100644
--- a/python/setup.cfg
+++ b/python/setup.cfg
@@ -35,7 +35,6 @@ install_requires =
[options.extras_require]
# Remember to update tests/minreqs.txt if changing anything below:
devel =
- avocado-framework >= 90.0
distlib >= 0.3.6
flake8 >= 5.0.4
fusepy >= 2.0.4
diff --git a/python/tests/flake8.sh b/python/tests/flake8.sh
deleted file mode 100755
index e0136996453..00000000000
--- a/python/tests/flake8.sh
+++ /dev/null
@@ -1,3 +0,0 @@
-#!/bin/sh -e
-python3 -m flake8 qemu/
-python3 -m flake8 scripts/
diff --git a/python/tests/iotests-mypy.sh b/python/tests/iotests-mypy.sh
deleted file mode 100755
index ee764708199..00000000000
--- a/python/tests/iotests-mypy.sh
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/bin/sh -e
-
-cd ../tests/qemu-iotests/
-python3 -m linters --mypy
diff --git a/python/tests/iotests-pylint.sh b/python/tests/iotests-pylint.sh
deleted file mode 100755
index 33c5ae900a5..00000000000
--- a/python/tests/iotests-pylint.sh
+++ /dev/null
@@ -1,5 +0,0 @@
-#!/bin/sh -e
-
-cd ../tests/qemu-iotests/
-# See commit message for environment variable explainer.
-SETUPTOOLS_USE_DISTUTILS=stdlib python3 -m linters --pylint
diff --git a/python/tests/isort.sh b/python/tests/isort.sh
deleted file mode 100755
index 66c2f7df0fd..00000000000
--- a/python/tests/isort.sh
+++ /dev/null
@@ -1,3 +0,0 @@
-#!/bin/sh -e
-python3 -m isort -c qemu/
-python3 -m isort -c scripts/
diff --git a/python/tests/minreqs.txt b/python/tests/minreqs.txt
index 19912027076..05c3bdb89f8 100644
--- a/python/tests/minreqs.txt
+++ b/python/tests/minreqs.txt
@@ -31,7 +31,6 @@ distlib==0.3.6
fusepy==2.0.4
# Test-runners, utilities, etc.
-avocado-framework==90.0
pytest==6.0.2
# Linters
diff --git a/python/tests/mypy.sh b/python/tests/mypy.sh
deleted file mode 100755
index a33a3f58ab3..00000000000
--- a/python/tests/mypy.sh
+++ /dev/null
@@ -1,3 +0,0 @@
-#!/bin/sh -e
-python3 -m mypy -p qemu
-python3 -m mypy scripts/
diff --git a/python/tests/pylint.sh b/python/tests/pylint.sh
deleted file mode 100755
index 2b68da90df7..00000000000
--- a/python/tests/pylint.sh
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/bin/sh -e
-# See commit message for environment variable explainer.
-SETUPTOOLS_USE_DISTUTILS=stdlib python3 -m pylint qemu/
-SETUPTOOLS_USE_DISTUTILS=stdlib python3 -m pylint scripts/
diff --git a/python/tests/qapi-flake8.sh b/python/tests/qapi-flake8.sh
deleted file mode 100755
index c69f9ea2e00..00000000000
--- a/python/tests/qapi-flake8.sh
+++ /dev/null
@@ -1,6 +0,0 @@
-#!/bin/sh -e
-# SPDX-License-Identifier: GPL-2.0-or-later
-
-python3 -m flake8 ../scripts/qapi/ \
- ../docs/sphinx/qapidoc.py \
- ../docs/sphinx/qapi_domain.py
diff --git a/python/tests/qapi-isort.sh b/python/tests/qapi-isort.sh
deleted file mode 100755
index 067c16d5d94..00000000000
--- a/python/tests/qapi-isort.sh
+++ /dev/null
@@ -1,8 +0,0 @@
-#!/bin/sh -e
-# SPDX-License-Identifier: GPL-2.0-or-later
-
-python3 -m isort --sp . -c ../scripts/qapi/
-# Force isort to recognize "compat" as a local module and not third-party
-python3 -m isort --sp . -c -p compat \
- ../docs/sphinx/qapi_domain.py \
- ../docs/sphinx/qapidoc.py
diff --git a/python/tests/qapi-mypy.sh b/python/tests/qapi-mypy.sh
deleted file mode 100755
index 363dbaf8c06..00000000000
--- a/python/tests/qapi-mypy.sh
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/bin/sh -e
-# SPDX-License-Identifier: GPL-2.0-or-later
-
-python3 -m mypy ../scripts/qapi
diff --git a/python/tests/qapi-pylint.sh b/python/tests/qapi-pylint.sh
deleted file mode 100755
index 8767d9d2a2d..00000000000
--- a/python/tests/qapi-pylint.sh
+++ /dev/null
@@ -1,8 +0,0 @@
-#!/bin/sh -e
-# SPDX-License-Identifier: GPL-2.0-or-later
-
-SETUPTOOLS_USE_DISTUTILS=stdlib python3 -m pylint \
- --rcfile=../scripts/qapi/pylintrc \
- ../scripts/qapi/ \
- ../docs/sphinx/qapidoc.py \
- ../docs/sphinx/qapi_domain.py
--
2.53.0
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH v4 4/4] python: add formal python3.14 support and testing
2026-02-26 21:33 [PATCH v4 0/4] Python: drop avocado, formally support python3.14 John Snow
` (2 preceding siblings ...)
2026-02-26 21:33 ` [PATCH v4 3/4] python: drop avocado John Snow
@ 2026-02-26 21:34 ` John Snow
3 siblings, 0 replies; 7+ messages in thread
From: John Snow @ 2026-02-26 21:34 UTC (permalink / raw)
To: qemu-devel
Cc: Alex Bennée, Cleber Rosa, John Snow, Thomas Huth,
Paolo Bonzini, Daniel P. Berrangé
Signed-off-by: John Snow <jsnow@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
---
configure | 4 ++--
python/setup.cfg | 3 ++-
2 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/configure b/configure
index 090579bf236..4e5efebab43 100755
--- a/configure
+++ b/configure
@@ -527,8 +527,8 @@ first_python=
if test -z "${PYTHON}"; then
# A bare 'python' is traditionally python 2.x, but some distros
# have it as python 3.x, so check in both places.
- for binary in python3 python python3.13 python3.12 python3.11 \
- python3.10 python3.9 ; do
+ for binary in python3 python python3.14 python3.13 python3.12 \
+ python3.11 python3.10 python3.9 ; do
if has "$binary"; then
python=$(command -v "$binary")
if check_py_version "$python"; then
diff --git a/python/setup.cfg b/python/setup.cfg
index e5bf498f0e1..80975933971 100644
--- a/python/setup.cfg
+++ b/python/setup.cfg
@@ -19,6 +19,7 @@ classifiers =
Programming Language :: Python :: 3.11
Programming Language :: Python :: 3.12
Programming Language :: Python :: 3.13
+ Programming Language :: Python :: 3.14
Typing :: Typed
[options]
@@ -162,7 +163,7 @@ multi_line_output=3
# of python available on your system to run this test.
[tox:tox]
-envlist = py39, py310, py311, py312, py313
+envlist = py39, py310, py311, py312, py313, py314
skip_missing_interpreters = true
[testenv]
--
2.53.0
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH v4 2/4] python: replace avocado tests with pytest
2026-02-26 21:33 ` [PATCH v4 2/4] python: replace avocado tests with pytest John Snow
@ 2026-02-27 8:09 ` Daniel P. Berrangé
2026-02-27 9:34 ` Thomas Huth
1 sibling, 0 replies; 7+ messages in thread
From: Daniel P. Berrangé @ 2026-02-27 8:09 UTC (permalink / raw)
To: John Snow
Cc: qemu-devel, Alex Bennée, Cleber Rosa, Thomas Huth,
Paolo Bonzini
On Thu, Feb 26, 2026 at 04:33:58PM -0500, John Snow wrote:
> Following suit with the rest of this repository, drop avocado and
> replace it with the Python standard "pytest" package.
>
> Our ultimate goal is to merge these python tests with the meson test
> suite, so the use of 'pytest' here is only a stop-gap solution to get
> the GitLab CI 'check-python-tox' passing again following recent Python
> packaging ecosystem changes.
>
> Signed-off-by: John Snow <jsnow@redhat.com>
> ---
> python/Makefile | 4 +-
> python/setup.cfg | 1 +
> python/tests/linters.py | 79 ++++++++++++++++++++++++++++++++++++++++
> python/tests/minreqs.txt | 1 +
> 4 files changed, 83 insertions(+), 2 deletions(-)
> create mode 100644 python/tests/linters.py
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
> +class TestLinters:
> +
> + def test_flake8_pkg(self):
> + check_call([sys.executable, "-m", "flake8", "qemu/"])
> +
> + def test_flake8_scripts(self):
> + check_call([sys.executable, "-m", "flake8", "scripts/"])
> +
> + def test_flake8_qapi(self):
> + check_call([sys.executable, "-m", "flake8",
> + "../scripts/qapi/",
> + "../docs/sphinx/qapidoc.py",
> + "../docs/sphinx/qapi_domain.py"])
Underindented.
> +
> + def test_isort_pkg(self):
> + check_call([sys.executable, "-m", "isort", "-c", "qemu/"])
> +
> + def test_isort_scripts(self):
> + check_call([sys.executable, "-m", "isort", "-c", "scripts/"])
> +
> + def test_isort_qapi(self):
> + check_call([sys.executable, "-m", "isort",
> + "--sp", ".", "-c", "../scripts/qapi/"])
> +
> + def test_isort_qapi_sphinx(self):
> + # Force isort to recognize 'compat' as a local module and not
> + # third-party
> + check_call([sys.executable, "-m", "isort",
> + "--sp", ".", "-c", "-p", "compat",
> + "../docs/sphinx/qapi_domain.py",
> + "../docs/sphinx/qapidoc.py"])
> +
...
> +
> + def test_pylint_qapi(self):
> + os.environ['SETUPTOOLS_USE_DISTUTILS'] = 'stdlib'
> + check_call([sys.executable, "-m", "pylint",
> + "--rcfile=../scripts/qapi/pylintrc",
> + "../scripts/qapi/",
> + "../docs/sphinx/qapidoc.py",
> + "../docs/sphinx/qapi_domain.py"])
Underindented.
> +
> + def test_pylint_iotests(self):
> + os.environ['SETUPTOOLS_USE_DISTUTILS'] = 'stdlib'
> + check_call([sys.executable, "-m", "linters", "--pylint"],
> + cwd="../tests/qemu-iotests/")
With regards,
Daniel
--
|: https://berrange.com ~~ https://hachyderm.io/@berrange :|
|: https://libvirt.org ~~ https://entangle-photo.org :|
|: https://pixelfed.art/berrange ~~ https://fstop138.berrange.com :|
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v4 2/4] python: replace avocado tests with pytest
2026-02-26 21:33 ` [PATCH v4 2/4] python: replace avocado tests with pytest John Snow
2026-02-27 8:09 ` Daniel P. Berrangé
@ 2026-02-27 9:34 ` Thomas Huth
1 sibling, 0 replies; 7+ messages in thread
From: Thomas Huth @ 2026-02-27 9:34 UTC (permalink / raw)
To: John Snow, qemu-devel; +Cc: Alex Bennée, Cleber Rosa, Paolo Bonzini
On 26/02/2026 22.33, John Snow wrote:
> Following suit with the rest of this repository, drop avocado and
> replace it with the Python standard "pytest" package.
>
> Our ultimate goal is to merge these python tests with the meson test
> suite, so the use of 'pytest' here is only a stop-gap solution to get
> the GitLab CI 'check-python-tox' passing again following recent Python
> packaging ecosystem changes.
>
> Signed-off-by: John Snow <jsnow@redhat.com>
> ---
> python/Makefile | 4 +-
> python/setup.cfg | 1 +
> python/tests/linters.py | 79 ++++++++++++++++++++++++++++++++++++++++
> python/tests/minreqs.txt | 1 +
> 4 files changed, 83 insertions(+), 2 deletions(-)
> create mode 100644 python/tests/linters.py
Reviewed-by: Thomas Huth <thuth@redhat.com>
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2026-02-27 9:35 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-02-26 21:33 [PATCH v4 0/4] Python: drop avocado, formally support python3.14 John Snow
2026-02-26 21:33 ` [PATCH v4 1/4] python: pin 'wheel' version in minreqs test John Snow
2026-02-26 21:33 ` [PATCH v4 2/4] python: replace avocado tests with pytest John Snow
2026-02-27 8:09 ` Daniel P. Berrangé
2026-02-27 9:34 ` Thomas Huth
2026-02-26 21:33 ` [PATCH v4 3/4] python: drop avocado John Snow
2026-02-26 21:34 ` [PATCH v4 4/4] python: add formal python3.14 support and testing John Snow
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.