All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Daniel P. Berrangé" <berrange@redhat.com>
To: John Snow <jsnow@redhat.com>
Cc: qemu-devel@nongnu.org, "Alex Bennée" <alex.bennee@linaro.org>,
	"Cleber Rosa" <crosa@redhat.com>,
	"Paolo Bonzini" <pbonzini@redhat.com>,
	"Thomas Huth" <thuth@redhat.com>
Subject: Re: [PATCH v2 2/4] python: replace avocado tests with pytest
Date: Fri, 27 Feb 2026 11:29:20 +0000	[thread overview]
Message-ID: <aaGAEFmarpoe0g-O@redhat.com> (raw)
In-Reply-To: <CAFn=p-YsiOiBy0VRdbXS0=PFtWkj_OzaMz+QPeku294=17mHXg@mail.gmail.com>

On Thu, Feb 26, 2026 at 12:51:46PM -0500, John Snow wrote:
> On Thu, Feb 26, 2026 at 9:26 AM Daniel P. Berrangé <berrange@redhat.com> wrote:
> >
> > On Wed, Feb 25, 2026 at 02:28:06PM -0500, John Snow wrote:
> > > Following suit with the rest of this repository, drop avocado and
> > > replace it with the Python standard "pytest" package.
> > >
> > > In this case, we do not truly need pytest as all we are using it for is
> > > running other python processes formerly launched by shell scripts, but
> > > this matches how the standalone python-qemu-qmp package does things,
> > > which keeps things simple on my end.
> >
> > From the POV of QEMU we don't really want 'pytest' in the loop
> > any more than we want avocado. The desire is for "meson" to be
> > the test harness.
> >
> > If this use of a pytest is just a temporary stepping stone
> > towards fully integrating with meson, then that's acceptable
> > but lets note that this is a temporary solution in the commit
> > message.
> 
> Admittedly I wasn't thinking about just using meson directly, so I
> suppose this *is* just a stepping stone. My only question for meson
> integration is how can I set up the deps so that "make check" will try
> to install the linting deps and run the python tests, but skips these
> tests if we are offline and don't have the deps. i.e. "try to run
> these tests, but don't error out if we can't"
> 
> Hazarding a guess: make the python tests depend on a linter group, add
> a custom target for that linter group, allow failure in that custom
> target (how?), then configure the individual meson test cases to skip
> if the deps are not present.
> 
> (Guess I'll go look at your older series and see how you handled this...)

I didn't handle the complexity of venvs in my old series. IIRC I just
blindly used the host python tools, since it was just PoC quality not
a mergable series.

When doing it for real, we'd end up wanting a selection of different
meson suites. Perhaps a default suite using the same python version
as meson itself, for integration in 'make check' and a set of extra
suites, one per python venv target for SPEED=thorough.

If --disable-download was given and the host tools for the linters
were missing we would have to skip the tests in 'make check', but
with SPEED=thorough we could auto-download everything.


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 :|



  reply	other threads:[~2026-02-27 11:30 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-02-25 19:28 [PATCH v2 0/4] Python: drop avocado, formally support python3.14 John Snow
2026-02-25 19:28 ` [PATCH v2 1/4] python: pin 'wheel' version in minreqs test John Snow
2026-02-26 14:04   ` Daniel P. Berrangé
2026-02-25 19:28 ` [PATCH v2 2/4] python: replace avocado tests with pytest John Snow
2026-02-26 14:26   ` Daniel P. Berrangé
2026-02-26 17:51     ` John Snow
2026-02-27 11:29       ` Daniel P. Berrangé [this message]
2026-02-25 19:28 ` [PATCH v2 3/4] python: drop avocado John Snow
2026-02-26 14:18   ` Daniel P. Berrangé
2026-02-25 19:28 ` [PATCH v2 4/4] python: add formal python3.14 support and testing John Snow
2026-02-26 14:06   ` Daniel P. Berrangé

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=aaGAEFmarpoe0g-O@redhat.com \
    --to=berrange@redhat.com \
    --cc=alex.bennee@linaro.org \
    --cc=crosa@redhat.com \
    --cc=jsnow@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --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.