qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Thomas Huth <thuth@redhat.com>
To: Max Reitz <mreitz@redhat.com>, qemu-block@nongnu.org
Cc: Kevin Wolf <kwolf@redhat.com>, qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH v2] iotests: Check for enabled drivers before testing them
Date: Tue, 3 Sep 2019 15:19:52 +0200	[thread overview]
Message-ID: <9a627de1-dd69-9e12-05cf-2baca8025f9c@redhat.com> (raw)
In-Reply-To: <3d606509-ffe4-eba6-3e40-2ab3e1e29607@redhat.com>


[-- Attachment #1.1: Type: text/plain, Size: 2676 bytes --]

On 03/09/2019 14.55, Max Reitz wrote:
> On 23.08.19 15:35, Thomas Huth wrote:
>> It is possible to enable only a subset of the block drivers with the
>> "--block-drv-rw-whitelist" option of the "configure" script. All other
>> drivers are marked as unusable (or only included as read-only with the
>> "--block-drv-ro-whitelist" option). If an iotest is now using such a
>> disabled block driver, it is failing - which is bad, since at least the
>> tests in the "auto" group should be able to deal with this situation.
>> Thus let's introduce a "_require_drivers" function that can be used by
>> the shell tests to check for the availability of certain drivers first,
>> and marks the test as "not run" if one of the drivers is missing.
>>
>> This patch mainly targets the test in the "auto" group which should
>> never fail in such a case, but also improves some of the other tests
>> along the way. Note that we also assume that the "qcow2" and "file"
>> drivers are always available - otherwise it does not make sense to
>> run "make check-block" at all (which only tests with qcow2 by default).
>>
>> Signed-off-by: Thomas Huth <thuth@redhat.com>
>> ---
>>  v2:
>>  - Update the check in _require_drivers() according to Max' suggestion
>>  - Remove superfluous check in test 081
>>  - Mark 120 to require "raw"
>>  - Replaced the check in 162 to use the new _require_drivers() function
>>  - Mark 186 to require "null-co"
>>
>>  tests/qemu-iotests/071       |  1 +
>>  tests/qemu-iotests/081       |  4 +---
>>  tests/qemu-iotests/099       |  1 +
>>  tests/qemu-iotests/120       |  1 +
>>  tests/qemu-iotests/162       |  4 +---
>>  tests/qemu-iotests/184       |  1 +
>>  tests/qemu-iotests/186       |  1 +
>>  tests/qemu-iotests/common.rc | 14 ++++++++++++++
>>  8 files changed, 21 insertions(+), 6 deletions(-)
> 
> This patch breaks these iotests when $DISPLAY is not set.  It does work
> with “iotests: Add -display none to the qemu options”.
> 
> Hm.  You reviewed that one, so I suppose I’ll just take it into v2 of my
> pull request as well.

Sounds like the righ way to go, thanks!

> (I’m not going to say having added the iotests to make check gives me as
> a maintainer more trouble than I had before, but, you know.)

I expected some initial trouble, since the iotests now get exposed to
much more different systems. But I hope it will pay off in the long run!
(Remember the 4.1 development cycles? The iotests have been completely
broken in the master branch by accident two or three times ... I hope at
least those days will now be gone or at least not happen that often anymore)

 Thomas


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

      reply	other threads:[~2019-09-03 13:21 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-23 13:35 [Qemu-devel] [PATCH v2] iotests: Check for enabled drivers before testing them Thomas Huth
2019-08-27 17:30 ` Max Reitz
2019-09-03 12:55 ` Max Reitz
2019-09-03 13:19   ` Thomas Huth [this message]

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=9a627de1-dd69-9e12-05cf-2baca8025f9c@redhat.com \
    --to=thuth@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=mreitz@redhat.com \
    --cc=qemu-block@nongnu.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).