From: Eryu Guan <eguan@redhat.com>
To: Amir Goldstein <amir73il@gmail.com>
Cc: Miklos Szeredi <miklos@szeredi.hu>, Xiong Zhou <xzhou@redhat.com>,
linux-unionfs@vger.kernel.org, fstests@vger.kernel.org
Subject: Re: [PATCH 1/5] overlay/017: silence test output
Date: Fri, 28 Apr 2017 13:36:33 +0800 [thread overview]
Message-ID: <20170428053633.GL26397@eguan.usersys.redhat.com> (raw)
In-Reply-To: <1493305775-12559-2-git-send-email-amir73il@gmail.com>
On Thu, Apr 27, 2017 at 06:09:31PM +0300, Amir Goldstein wrote:
> Change test to output golden silence on success.
Some words on why this change is needed would be good.
>
> Signed-off-by: Amir Goldstein <amir73il@gmail.com>
> ---
> tests/overlay/017 | 4 +++-
> tests/overlay/017.out | 7 +------
> 2 files changed, 4 insertions(+), 7 deletions(-)
>
> diff --git a/tests/overlay/017 b/tests/overlay/017
> index 5ca3040..d6ba2ae 100755
> --- a/tests/overlay/017
> +++ b/tests/overlay/017
> @@ -89,11 +89,13 @@ done
>
> # find by inode number - expect to find file by inode number
> cat $tmp.before | while read ino f; do
> - find $f -inum $ino -maxdepth 0 | _filter_scratch
> + find $SCRATCH_MNT/ -inum $ino -maxdepth 1 | grep -q $f || \
> + echo "$f not found by ino $ino"
Hmm, if I run this find command manually, I got warning about -maxdepth
position.
# find `pwd` -inum 3932421 -maxdepth 1
find: warning: you have specified the -maxdepth option after a non-option argument -inum, but options are not positional (-maxdepth affects tests specified before it as well as those specified after it). Please specify options before other arguments.
/root/xfstests/check
Move -maxdepth option just after find path works fine
# find `pwd` -maxdepth 1 -inum 3932421
/root/xfstests/check
But I'm not sure why I didn't see this warning by running overlay/017..
Anyway, moving -maxdepth around seems better to me.
Thanks,
Eryu
> done
>
> # Compare before..after - expect silence
> diff $tmp.before $tmp.after
>
> +echo "Silence is golden"
> status=0
> exit
> diff --git a/tests/overlay/017.out b/tests/overlay/017.out
> index 1f277c5..8222844 100644
> --- a/tests/overlay/017.out
> +++ b/tests/overlay/017.out
> @@ -1,7 +1,2 @@
> QA output created by 017
> -SCRATCH_MNT/dir
> -SCRATCH_MNT/file
> -SCRATCH_MNT/symlink
> -SCRATCH_MNT/chrdev
> -SCRATCH_MNT/blkdev
> -SCRATCH_MNT/fifo
> +Silence is golden
> --
> 2.7.4
>
next prev parent reply other threads:[~2017-04-28 5:36 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-04-27 15:09 [PATCH 0/5] fstests: more tests for overlay constant inode numbers Amir Goldstein
2017-04-27 15:09 ` [PATCH 1/5] overlay/017: silence test output Amir Goldstein
2017-04-28 5:36 ` Eryu Guan [this message]
2017-04-28 5:45 ` Amir Goldstein
2017-04-28 5:50 ` Eryu Guan
2017-04-28 6:34 ` Amir Goldstein
2017-04-28 6:50 ` Eryu Guan
2017-04-27 15:09 ` [PATCH 2/5] overlay/017: use af_unix to create socket test file Amir Goldstein
2017-04-27 15:09 ` [PATCH 3/5] overlay/017: create a helper to record inode number Amir Goldstein
2017-04-27 15:09 ` [PATCH 4/5] overlay/017: verify constant inode number after rename Amir Goldstein
2017-04-28 5:47 ` Eryu Guan
2017-04-28 5:50 ` Amir Goldstein
2017-04-27 15:09 ` [PATCH 5/5] overlay/017: test persistent inode numbers after mount cycle Amir Goldstein
2017-04-28 5:30 ` [PATCH 0/5] fstests: more tests for overlay constant inode numbers Eryu Guan
2017-04-28 5:39 ` Amir Goldstein
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=20170428053633.GL26397@eguan.usersys.redhat.com \
--to=eguan@redhat.com \
--cc=amir73il@gmail.com \
--cc=fstests@vger.kernel.org \
--cc=linux-unionfs@vger.kernel.org \
--cc=miklos@szeredi.hu \
--cc=xzhou@redhat.com \
/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