public inbox for passt-dev@passt.top
 help / color / mirror / code / Atom feed
From: David Gibson <david@gibson.dropbear.id.au>
To: passt-dev@passt.top
Subject: Re: [PATCH 2/3] tests: Don't count number of test units for demos
Date: Thu, 19 May 2022 13:48:47 +1000	[thread overview]
Message-ID: <YoW+H8uUFn+qfXRN@yekko> (raw)
In-Reply-To: <20220518232829.2775820-3-sbrivio@redhat.com>

[-- Attachment #1: Type: text/plain, Size: 1047 bytes --]

On Thu, May 19, 2022 at 01:28:28AM +0200, Stefano Brivio wrote:
> ...there are no 'test' directives in demo, and this causes a
> script failure.
> 
> Signed-off-by: Stefano Brivio <sbrivio(a)redhat.com>

Reviewed-by: David Gibson <david(a)gibson.dropbear.id.au>

> ---
>  test/lib/test | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/test/lib/test b/test/lib/test
> index a5583e3..09e8340 100755
> --- a/test/lib/test
> +++ b/test/lib/test
> @@ -386,8 +386,10 @@ test_one() {
>  		return
>  	fi
>  
> -	__ntests="$(grep -c "^test$(printf '\t')" "${__test_file}")"
> -	[ ${DEMO} -eq 0 ] && status_file_start "${1}" "${__ntests}"
> +	if [ ${DEMO} -eq 0 ]; then
> +		__ntests="$(grep -c "^test$(printf '\t')" "${__test_file}")"
> +		status_file_start "${1}" "${__ntests}"
> +	fi
>  
>  	[ ${CI} -eq 1 ] && video_link "${1}"
>  

-- 
David Gibson			| I'll have my music baroque, and my code
david AT gibson.dropbear.id.au	| minimalist, thank you.  NOT _the_ _other_
				| _way_ _around_!
http://www.ozlabs.org/~dgibson

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

  reply	other threads:[~2022-05-19  3:48 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-18 23:28 [PATCH 0/3] tests: A few fixes for demos Stefano Brivio
2022-05-18 23:28 ` [PATCH 1/3] demo/pasta: Fix bad sleep directive Stefano Brivio
2022-05-19  3:48   ` David Gibson
2022-05-18 23:28 ` [PATCH 2/3] tests: Don't count number of test units for demos Stefano Brivio
2022-05-19  3:48   ` David Gibson [this message]
2022-05-18 23:28 ` [PATCH 3/3] tests: Don't check exit code for every command in demo mode Stefano Brivio
2022-05-19  3:49   ` David Gibson

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=YoW+H8uUFn+qfXRN@yekko \
    --to=david@gibson.dropbear.id.au \
    --cc=passt-dev@passt.top \
    /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.
Code repositories for project(s) associated with this public inbox

	https://passt.top/passt

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 IMAP folder(s).