All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jan Tulak <jtulak@redhat.com>
To: fstests@vger.kernel.org
Cc: david@fromorbit.com, eguan@redhat.com, Jan Tulak <jtulak@redhat.com>
Subject: [PATCH v3] xfstests: update xfs/096 for new behaviour
Date: Fri,  1 Jul 2016 18:14:34 +0200	[thread overview]
Message-ID: <1467389674-5341-1-git-send-email-jtulak@redhat.com> (raw)
In-Reply-To: <1464858659-610-1-git-send-email-jtulak@redhat.com>

Because we recently changed how mkfs behaves when it gets incorrect/invalid
values, add a feature check to run this test only on older binaries, which
accepts invalid sunit values.

Signed-off-by: Jan Tulak <jtulak@redhat.com>
---
UPDATE:
Change it to _notrun on newer binaries. Commit message updated respectivvely.
---
 tests/xfs/096 | 22 ++++++++++++++++++----
 1 file changed, 18 insertions(+), 4 deletions(-)

diff --git a/tests/xfs/096 b/tests/xfs/096
index f949e83..803b49d 100755
--- a/tests/xfs/096
+++ b/tests/xfs/096
@@ -39,6 +39,20 @@ _cleanup()
     rm -f $tmp.*
 }
 
+# maximum log record size
+max_lr_size=`expr 256 \* 1024`
+big_su=`expr $max_lr_size + 4096`
+
+requires_mkfs_accept_invalid_log_sunit()
+{
+	accepts=`mkfs.xfs -N -l version=2,su=$big_su 2>&1 | \
+		grep -ci "No device name"`
+	if [ "$accepts" -eq 0 ];then
+		_notrun "Runs only on older xfsprogs accepting invalid log sunit"
+	fi
+	return 1
+}
+
 # get standard environment, filters and checks
 . ./common/rc
 . ./common/filter
@@ -97,6 +111,9 @@ mkfs_filter()
    | grep -v parent
 }
 
+# skip on newer versions
+requires_mkfs_accept_invalid_log_sunit
+
 # real QA test starts here
 rm -f $seqres.full
 
@@ -108,16 +125,13 @@ _require_v2log
 
 # choose .out file based on internal/external log
 rm -f $seqfull.out
+
 if [ "$USE_EXTERNAL" = yes ]; then
 	ln -s $seq.out.external $seqfull.out
 else
 	ln -s $seq.out.internal $seqfull.out
 fi
 
-# maximum log record size
-max_lr_size=`expr 256 \* 1024`
-
-big_su=`expr $max_lr_size + 4096`
 
 #
 # Test out various mkfs param combinations
-- 
2.5.5


  parent reply	other threads:[~2016-07-01 16:14 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-02  9:10 [PATCH] xfstests: update xfs/096 for new behaviour Jan Tulak
2016-06-07  3:45 ` Eryu Guan
     [not found]   ` <CACj3i733G7oz_tg4NANfz_=X5nYMp31k-FskEPXxHsaSxKtTEw@mail.gmail.com>
2016-06-07  8:31     ` Fwd: " Jan Tulak
2016-06-23 11:22     ` Jan Tulak
2016-06-23 11:41       ` Jan Tulak
2016-06-29 10:18 ` [PATCH v2] " Jan Tulak
2016-06-30  6:54   ` Eryu Guan
2016-07-01  0:37     ` Dave Chinner
2016-07-01  3:05       ` Eryu Guan
2016-07-01 12:12         ` Jan Tulak
2016-07-01 16:14 ` Jan Tulak [this message]
2016-07-13 10:38   ` [PATCH v3] " Eryu Guan
2016-07-14 10:25     ` Jan Tulak

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=1467389674-5341-1-git-send-email-jtulak@redhat.com \
    --to=jtulak@redhat.com \
    --cc=david@fromorbit.com \
    --cc=eguan@redhat.com \
    --cc=fstests@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 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.