Linux Kernel Selftest development
 help / color / mirror / Atom feed
From: Shuah Khan <skhan@linuxfoundation.org>
To: Rishabh Bhatnagar <risbhat@amazon.com>, shuah@kernel.org
Cc: linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org,
	Shuah Khan <skhan@linuxfoundation.org>
Subject: Re: [PATCH] kselftests: Sort the collections list to avoid duplicate tests
Date: Mon, 5 Jun 2023 13:40:20 -0600	[thread overview]
Message-ID: <93651468-daa2-1530-f94e-b66a4fd4bdf8@linuxfoundation.org> (raw)
In-Reply-To: <20230601211112.12724-1-risbhat@amazon.com>

On 6/1/23 15:11, Rishabh Bhatnagar wrote:
> If the collections list is not sorted uniq doesn't weed out duplicate
> tests correctly. Make sure to sort it before running uniq.
> 
> Signed-off-by: Rishabh Bhatnagar <risbhat@amazon.com>
> ---
>   tools/testing/selftests/run_kselftest.sh | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/tools/testing/selftests/run_kselftest.sh b/tools/testing/selftests/run_kselftest.sh
> index 97165a83df63..e0cb10c85169 100755
> --- a/tools/testing/selftests/run_kselftest.sh
> +++ b/tools/testing/selftests/run_kselftest.sh
> @@ -85,7 +85,7 @@ if [ -n "$TESTS" ]; then
>   	available="$(echo "$valid" | sed -e 's/ /\n/g')"
>   fi
>   
> -collections=$(echo "$available" | cut -d: -f1 | uniq)
> +collections=$(echo "$available" | cut -d: -f1 | sort | uniq)
>   for collection in $collections ; do
>   	[ -w /dev/kmsg ] && echo "kselftest: Running tests in $collection" >> /dev/kmsg
>   	tests=$(echo "$available" | grep "^$collection:" | cut -d: -f2)

Applied to linux-kselftest next for Linux 6.5-rc1.

thanks,
-- Shuah

      reply	other threads:[~2023-06-05 19:40 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-01 21:11 [PATCH] kselftests: Sort the collections list to avoid duplicate tests Rishabh Bhatnagar
2023-06-05 19:40 ` Shuah Khan [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=93651468-daa2-1530-f94e-b66a4fd4bdf8@linuxfoundation.org \
    --to=skhan@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=risbhat@amazon.com \
    --cc=shuah@kernel.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