All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Alex Bennée" <alex.bennee@linaro.org>
To: Thomas Huth <thuth@redhat.com>
Cc: Kevin Wolf <kwolf@redhat.com>,
	qemu-devel@nongnu.org, qemu-block@nongnu.org,
	Max Reitz <mreitz@redhat.com>
Subject: Re: [Qemu-devel] [PATCH v2 1/4] tests/qemu-iotests/check: Allow tests without groups
Date: Tue, 16 Jul 2019 16:52:29 +0100	[thread overview]
Message-ID: <87a7deugci.fsf@zen.linaroharston> (raw)
In-Reply-To: <20190716122836.31187-2-thuth@redhat.com>


Thomas Huth <thuth@redhat.com> writes:

> The regular expressions in the "check" script currently expect that there
> is always a space after the test number in the group file, so you can't
> have a test in there without a group unless the line still ends with a
> space - which is quite error prone since some editors might remove spaces
> at the end of lines automatically.
> Thus let's fix the regular expressions so that it is also possible to
> have lines with one test number only in the group file.
>
> Suggested-by: Max Reitz <mreitz@redhat.com>
> Signed-off-by: Thomas Huth <thuth@redhat.com>

Reviewed-by: Alex Bennée <alex.bennee@linaro.org>

> ---
>  tests/qemu-iotests/check | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/tests/qemu-iotests/check b/tests/qemu-iotests/check
> index f925606cc5..c24874ff4a 100755
> --- a/tests/qemu-iotests/check
> +++ b/tests/qemu-iotests/check
> @@ -488,7 +488,7 @@ testlist options
>  BEGIN        { for (t='$start'; t<='$end'; t++) printf "%03d\n",t }' \
>          | while read id
>          do
> -            if grep -s "^$id " "$source_iotests/group" >/dev/null
> +            if grep -s "^$id\( \|\$\)" "$source_iotests/group" >/dev/null
>              then
>                  # in group file ... OK
>                  echo $id >>$tmp.list
> @@ -547,7 +547,7 @@ else
>          touch $tmp.list
>      else
>          # no test numbers, do everything from group file
> -        sed -n -e '/^[0-9][0-9][0-9]*/s/[         ].*//p' <"$source_iotests/group" >$tmp.list
> +        sed -n -e '/^[0-9][0-9][0-9]*/s/^\([0-9]*\).*/\1/p' <"$source_iotests/group" >$tmp.list
>      fi
>  fi


--
Alex Bennée


  parent reply	other threads:[~2019-07-16 15:52 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-16 12:28 [Qemu-devel] [PATCH v2 0/4] Enable iotests during "make check" Thomas Huth
2019-07-16 12:28 ` [Qemu-devel] [PATCH v2 1/4] tests/qemu-iotests/check: Allow tests without groups Thomas Huth
2019-07-16 15:27   ` Max Reitz
2019-07-16 15:52   ` Alex Bennée [this message]
2019-07-16 12:28 ` [Qemu-devel] [PATCH v2 2/4] tests/qemu-iotests/group: Remove some more tests from the "auto" group Thomas Huth
2019-07-16 15:26   ` Max Reitz
2019-07-16 15:31     ` Thomas Huth
2019-07-16 15:44       ` Max Reitz
2019-07-16 15:45         ` Max Reitz
2019-07-16 15:56         ` Eric Blake
2019-07-16 15:58           ` Max Reitz
2019-07-16 16:09             ` Eric Blake
2019-07-16 16:12               ` Max Reitz
2019-07-18  7:42                 ` Thomas Huth
2019-07-16 12:28 ` [Qemu-devel] [PATCH v2 3/4] tests: Run the iotests during "make check" again Thomas Huth
2019-07-16 15:37   ` Max Reitz
2019-07-17  9:41     ` Thomas Huth
2019-07-16 12:28 ` [Qemu-devel] [PATCH v2 4/4] gitlab-ci: Remove qcow2 tests that are handled by "make check" already Thomas Huth
2019-07-16 15:41   ` Max Reitz
2019-07-16 15:51     ` Thomas Huth
2019-07-16 15:57       ` Max Reitz

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=87a7deugci.fsf@zen.linaroharston \
    --to=alex.bennee@linaro.org \
    --cc=kwolf@redhat.com \
    --cc=mreitz@redhat.com \
    --cc=qemu-block@nongnu.org \
    --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.