Linux EXT4 FS development
 help / color / mirror / Atom feed
From: Zorro Lang <zlang@kernel.org>
To: fstests@vger.kernel.org
Cc: Theodore Ts'o <tytso@mit.edu>, linux-ext4@vger.kernel.org
Subject: [RFC PATCH 3/4] check: add --loop-on-fail long name for -L
Date: Wed, 11 Nov 2026 01:09:19 +0800	[thread overview]
Message-ID: <20261110170920.3302511-4-zlang@kernel.org> (raw)
In-Reply-To: <20261110170920.3302511-1-zlang@kernel.org>

The -L option reruns a test <n> times after its first failure.  Give
it the long name --loop-on-fail so that all the per-test looping
options can be described consistently as a --loop family.

Signed-off-by: Zorro Lang <zlang@kernel.org>
---
 check | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/check b/check
index b30532cf..96e4f2fd 100755
--- a/check
+++ b/check
@@ -70,7 +70,7 @@ General options:
                               iterate the test list <n> times, but stops
                               iterating further in case of any test failure
     -l                      line mode diff
-    -L <n>                  loop tests <n> times following a failure, measuring
+    -L, --loop-on-fail <n>  loop tests <n> times following a failure, measuring
                               aggregate pass/fail metrics
     --loop <n>              run each test <n> times, measuring aggregate
                               pass/fail metrics (test fails if any run fails)
@@ -402,7 +402,7 @@ _set_loop_mode()
 
 	[[ $count =~ ^[0-9]+$ ]] || usage
 	if [ -n "$loop_mode" ] && [ "$loop_mode" != "$mode" ]; then
-		echo "check: conflicting loop modes: -L and --loop are mutually exclusive" >&2
+		echo "check: conflicting loop modes: -L, --loop-on-fail and --loop are mutually exclusive" >&2
 		usage
 	fi
 	loop_mode="$mode"
@@ -418,7 +418,7 @@ _set_loop_mode()
 parse_check_args()
 {
 	local short_opts="g:x:X:e:E:s:S:lnri:I:TdbR:L:h"
-	local long_opts="fs:,exact-order,large-fs,extra-space:,udiff,help,iterate:,iterate-while-successful:,loop:"
+	local long_opts="fs:,exact-order,large-fs,extra-space:,udiff,help,iterate:,iterate-while-successful:,loop:,loop-on-fail:"
 
 	compat_old_option "$@"
 
@@ -526,7 +526,7 @@ parse_check_args()
 			export SCRATCH_DEV_EMPTY_SPACE="$2"
 			shift
 			;;
-		-L)
+		-L|--loop-on-fail)
 			_set_loop_mode on-fail "$2"
 			shift
 			;;
-- 
2.56.0


  parent reply	other threads:[~2026-11-10 17:09 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-10 17:09 [RFC PATCH 0/4] check: add --loop* family options for repeating tests Zorro Lang
2026-11-10 17:09 ` [RFC PATCH 1/4] check: add long aliases --iterate and --iterate-while-successful Zorro Lang
2026-11-10 17:09 ` [RFC PATCH 2/4] check: add --loop option to run each test multiple times Zorro Lang
2026-11-10 17:09 ` Zorro Lang [this message]
2026-11-10 17:09 ` [RFC PATCH 4/4] check: add --loop-while-successful option Zorro Lang

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=20261110170920.3302511-4-zlang@kernel.org \
    --to=zlang@kernel.org \
    --cc=fstests@vger.kernel.org \
    --cc=linux-ext4@vger.kernel.org \
    --cc=tytso@mit.edu \
    /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