xfs/148: sort attribute list output
authorDarrick J. Wong <darrick.wong@oracle.com>
Wed, 4 Dec 2019 02:36:42 +0000 (18:36 -0800)
committerEryu Guan <guaneryu@gmail.com>
Sun, 8 Dec 2019 15:51:06 +0000 (23:51 +0800)
Yang Xu reported a test failure in xfs/148 that I think comes from
extended attributes being returned in a different order than they were
set.  Since order isn't important in this test, sort the output to make
it consistent.

Reported-by: Yang Xu <xuyang2018.ky@cn.fujitsu.com>
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Eryu Guan <guaneryu@gmail.com>
tests/xfs/148
tests/xfs/148.out

index 42cfdab0e39a8aee61f1ba70fcf64be43639c8fd..ec1d0ecede33dc9b8506ab8b6f7af4644ff5d311 100755 (executable)
@@ -76,7 +76,7 @@ test_names+=("too_many" "are_bad/for_you")
 
 access_stuff() {
        ls $testdir
-       $ATTR_PROG -l $testfile
+       $ATTR_PROG -l $testfile | grep 'a_' | sort
 
        for name in "${test_names[@]}"; do
                ls "$testdir/f_$name"
index c301ecb6e1510085d5488b749539bc606bb09949..f95b55b7ee9db0eab7a80772fcd83eb6204a4b1b 100644 (file)
@@ -4,10 +4,10 @@ f_another
 f_are_bad_for_you
 f_something
 f_too_many_beans
+Attribute "a_another" has a 3 byte value for TEST_DIR/mount-148/testfile
+Attribute "a_are_bad_for_you" has a 3 byte value for TEST_DIR/mount-148/testfile
 Attribute "a_something" has a 3 byte value for TEST_DIR/mount-148/testfile
 Attribute "a_too_many_beans" has a 3 byte value for TEST_DIR/mount-148/testfile
-Attribute "a_are_bad_for_you" has a 3 byte value for TEST_DIR/mount-148/testfile
-Attribute "a_another" has a 3 byte value for TEST_DIR/mount-148/testfile
 TEST_DIR/mount-148/testdir/f_something
 Attribute "a_something" had a 3 byte value for TEST_DIR/mount-148/testfile:
 heh