xfs/263: don't hardcode inode numbers in output
authorDarrick J. Wong <darrick.wong@oracle.com>
Sat, 28 Jan 2017 17:38:12 +0000 (09:38 -0800)
committerEryu Guan <eguan@redhat.com>
Sat, 4 Feb 2017 06:15:55 +0000 (14:15 +0800)
Since we can't control the inode number assignments when creating files,
don't hardcode them in the golden output.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Eryu Guan <eguan@redhat.com>
Signed-off-by: Eryu Guan <eguan@redhat.com>
tests/xfs/263
tests/xfs/263.out

index 1dc47aedd3ce5fe923052deb386da235dcab8909..7aebf90b820e1be96f208ba74d6fe2c53d06fb11 100755 (executable)
@@ -71,6 +71,10 @@ function option_string()
        echo $OPT
 }
 
+filter_quota_state() {
+       sed -e 's/Inode: #[0-9]\+/Inode #XXX/g' | _filter_scratch
+}
+
 function test_all_state()
 {
        for I in `seq 0 7`; do
@@ -79,7 +83,7 @@ function test_all_state()
                # Some combinations won't mount on V4 supers (grp + prj)
                _qmount_option "$OPTIONS"
                _scratch_mount &>> $seqres.full || continue
-               $XFS_QUOTA_PROG -x -c "state" $SCRATCH_MNT | _filter_scratch
+               $XFS_QUOTA_PROG -x -c "state" $SCRATCH_MNT | filter_quota_state
                _scratch_unmount
        done
 }
index 70454dd40a1e0dcdc7ec586e01e82791b166016b..531d45de56e1acbe68c308cc88a7a50fe92b6ee4 100644 (file)
@@ -5,7 +5,7 @@ QA output created by 263
 User quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: ON
   Enforcement: ON
-  Inode: #131 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Group quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: OFF
   Enforcement: OFF
@@ -21,11 +21,11 @@ Realtime Blocks grace time: [7 days]
 User quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: OFF
   Enforcement: OFF
-  Inode: #131 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Group quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: ON
   Enforcement: ON
-  Inode: #132 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Project quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: OFF
   Enforcement: OFF
@@ -37,11 +37,11 @@ Realtime Blocks grace time: [7 days]
 User quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: ON
   Enforcement: ON
-  Inode: #131 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Group quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: ON
   Enforcement: ON
-  Inode: #132 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Project quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: OFF
   Enforcement: OFF
@@ -53,7 +53,7 @@ Realtime Blocks grace time: [7 days]
 User quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: OFF
   Enforcement: OFF
-  Inode: #131 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Group quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: OFF
   Enforcement: OFF
@@ -61,7 +61,7 @@ Group quota state on SCRATCH_MNT (SCRATCH_DEV)
 Project quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: ON
   Enforcement: ON
-  Inode: #132 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Blocks grace time: [7 days]
 Inodes grace time: [7 days]
 Realtime Blocks grace time: [7 days]
@@ -69,7 +69,7 @@ Realtime Blocks grace time: [7 days]
 User quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: ON
   Enforcement: ON
-  Inode: #131 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Group quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: OFF
   Enforcement: OFF
@@ -77,7 +77,7 @@ Group quota state on SCRATCH_MNT (SCRATCH_DEV)
 Project quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: ON
   Enforcement: ON
-  Inode: #132 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Blocks grace time: [7 days]
 Inodes grace time: [7 days]
 Realtime Blocks grace time: [7 days]
@@ -89,7 +89,7 @@ Realtime Blocks grace time: [7 days]
 User quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: ON
   Enforcement: ON
-  Inode: #99 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Group quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: OFF
   Enforcement: OFF
@@ -105,11 +105,11 @@ Realtime Blocks grace time: [7 days]
 User quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: OFF
   Enforcement: OFF
-  Inode: #99 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Group quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: ON
   Enforcement: ON
-  Inode: #100 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Project quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: OFF
   Enforcement: OFF
@@ -121,11 +121,11 @@ Realtime Blocks grace time: [7 days]
 User quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: ON
   Enforcement: ON
-  Inode: #99 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Group quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: ON
   Enforcement: ON
-  Inode: #100 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Project quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: OFF
   Enforcement: OFF
@@ -137,15 +137,15 @@ Realtime Blocks grace time: [7 days]
 User quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: OFF
   Enforcement: OFF
-  Inode: #99 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Group quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: OFF
   Enforcement: OFF
-  Inode: #100 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Project quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: ON
   Enforcement: ON
-  Inode: #101 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Blocks grace time: [7 days]
 Inodes grace time: [7 days]
 Realtime Blocks grace time: [7 days]
@@ -153,15 +153,15 @@ Realtime Blocks grace time: [7 days]
 User quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: ON
   Enforcement: ON
-  Inode: #99 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Group quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: OFF
   Enforcement: OFF
-  Inode: #100 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Project quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: ON
   Enforcement: ON
-  Inode: #101 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Blocks grace time: [7 days]
 Inodes grace time: [7 days]
 Realtime Blocks grace time: [7 days]
@@ -169,15 +169,15 @@ Realtime Blocks grace time: [7 days]
 User quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: OFF
   Enforcement: OFF
-  Inode: #99 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Group quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: ON
   Enforcement: ON
-  Inode: #100 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Project quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: ON
   Enforcement: ON
-  Inode: #101 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Blocks grace time: [7 days]
 Inodes grace time: [7 days]
 Realtime Blocks grace time: [7 days]
@@ -185,15 +185,15 @@ Realtime Blocks grace time: [7 days]
 User quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: ON
   Enforcement: ON
-  Inode: #99 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Group quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: ON
   Enforcement: ON
-  Inode: #100 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Project quota state on SCRATCH_MNT (SCRATCH_DEV)
   Accounting: ON
   Enforcement: ON
-  Inode: #101 (1 blocks, 1 extents)
+  Inode #XXX (1 blocks, 1 extents)
 Blocks grace time: [7 days]
 Inodes grace time: [7 days]
 Realtime Blocks grace time: [7 days]