From: Theodore Ts'o <tytso@mit.edu>
To: Ext4 Developers List <linux-ext4@vger.kernel.org>
Cc: Theodore Ts'o <tytso@mit.edu>
Subject: [PATCH 4/4] tests: fix the e2fsck test script to handle a missing test name
Date: Thu, 31 May 2012 20:14:58 -0400 [thread overview]
Message-ID: <1338509698-24349-4-git-send-email-tytso@mit.edu> (raw)
In-Reply-To: <1338509698-24349-1-git-send-email-tytso@mit.edu>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
---
tests/run_e2fsck | 17 ++++++++++++++---
1 file changed, 14 insertions(+), 3 deletions(-)
diff --git a/tests/run_e2fsck b/tests/run_e2fsck
index 937a171..ab623e8 100644
--- a/tests/run_e2fsck
+++ b/tests/run_e2fsck
@@ -82,12 +82,23 @@ if [ "$SKIP_VERIFY" != "true" ] ; then
status3=0
fi
+ if [ -z "$test_description" ] ; then
+ description="$test_name"
+ else
+ description="$test_name: $test_description"
+ fi
+
if [ "$status1" -eq 0 -a "$status2" -eq 0 -a "$status3" -eq 0 ] ; then
- echo "$test_name: $test_description: ok"
+ echo "$description: ok"
touch $test_name.ok
else
- echo "$test_name: $test_description: failed"
- diff $DIFF_OPTS $EXP1 $OUT1 > $test_name.failed
+ echo "$description: failed"
+ rm -f $test_name.failed
+ if [ "$PASS_ZERO" = "true" ]; then
+ diff $DIFF_OPTS $test_dir/expect.0 \
+ $test_name.0.log >> $test_name.failed
+ fi
+ diff $DIFF_OPTS $EXP1 $OUT1 >> $test_name.failed
if [ "$ONE_PASS_ONLY" != "true" ]; then
diff $DIFF_OPTS $EXP2 $OUT2 >> $test_name.failed
fi
--
1.7.10.2.552.gaa3bb87
prev parent reply other threads:[~2012-06-01 0:15 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-06-01 0:14 [PATCH 1/4] dumpe2fs: print journal's s_errno field if it is non-zero Theodore Ts'o
2012-06-01 0:14 ` [PATCH 2/4] e2fsck: handle an already recovered journal with a non-zero s_error field Theodore Ts'o
2012-06-01 0:14 ` [PATCH 3/4] tests: add new test to validate errno handling in the journal superblock Theodore Ts'o
2012-06-01 0:14 ` Theodore Ts'o [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=1338509698-24349-4-git-send-email-tytso@mit.edu \
--to=tytso@mit.edu \
--cc=linux-ext4@vger.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;
as well as URLs for NNTP newsgroup(s).