Update QA tests to work with new attribute code (trusted namespace).

This commit is contained in:
fsgqa
2003-02-25 09:13:13 +00:00
parent 2b381ac8df
commit 4044dd3050
3 changed files with 162 additions and 162 deletions
+8 -8
View File
@@ -96,7 +96,7 @@ mkfs_xfs $SCRATCH_DEV | _filter_mkfs 2>$tmp.mkfs
mount -t xfs $SCRATCH_DEV $SCRATCH_MNT || _fail "mount failed"
_create_test_bed
for nsp in user xfsroot; do
for nsp in user trusted; do
for inode in reg dir lnk dev/b dev/c dev/p; do
echo; echo "=== TYPE $inode; NAMESPACE $nsp"; echo
@@ -137,7 +137,7 @@ for nsp in user xfsroot; do
getfattr -m $nsp -e hex -n $nsp.name2 $SCRATCH_MNT/$inode
echo "*** final list (strings, type=$inode, nsp=$nsp)"
getfattr -m '^user|^xfsroot' -e hex $SCRATCH_MNT/$inode
getfattr -m '^user|^trusted' -e hex $SCRATCH_MNT/$inode
done
done
@@ -155,8 +155,8 @@ _extend_test_bed()
mkdir -p $SCRATCH_MNT/descend/down/here
find $SCRATCH_MNT/descend | xargs setfattr -n user.x -v yz
find $SCRATCH_MNT/descend | xargs setfattr -n user.1 -v 23
find $SCRATCH_MNT/here | xargs setfattr -n xfsroot.a -v bc
find $SCRATCH_MNT/here | xargs setfattr -n xfsroot.9 -v 87
find $SCRATCH_MNT/here | xargs setfattr -n trusted.a -v bc
find $SCRATCH_MNT/here | xargs setfattr -n trusted.9 -v 87
# whack a symlink in the middle, just to be difficult
ln -s $SCRATCH_MNT/here/up $SCRATCH_MNT/descend/and
# dump out our new starting point
@@ -167,11 +167,11 @@ _extend_test_bed
echo
echo "*** directory descent with us following symlinks"
getfattr -h -L -R -m '^user|^xfsroot' -e hex $SCRATCH_MNT
getfattr -h -L -R -m '^user|^trusted' -e hex $SCRATCH_MNT
echo
echo "*** directory descent without following symlinks"
getfattr -h -P -R -m '^user|^xfsroot' -e hex $SCRATCH_MNT
getfattr -h -P -R -m '^user|^trusted' -e hex $SCRATCH_MNT
#
@@ -194,7 +194,7 @@ _backup $tmp.backup1
echo "*** clear out the scratch device"
rm -fr $SCRATCH_MNT/*
echo "AFTER REMOVE" >>$seq.full
getfattr -L -R -m '^user|^xfsroot' $SCRATCH_MNT >>$seq.full
getfattr -L -R -m '^user|^trusted' $SCRATCH_MNT >>$seq.full
echo "*** reset test bed with no extended attributes"
_create_test_bed
@@ -205,7 +205,7 @@ setfattr -h --restore=$tmp.backup1
_backup $tmp.backup2
echo "AFTER RESTORE" >>$seq.full
getfattr -L -R -m '^user|^xfsroot' $SCRATCH_MNT >>$seq.full
getfattr -L -R -m '^user|^trusted' $SCRATCH_MNT >>$seq.full
echo "*** compare before and after backups"
diff $tmp.backup1 $tmp.backup2
+152 -152
View File
File diff suppressed because it is too large Load Diff
+2 -2
View File
@@ -1170,10 +1170,10 @@ _get_eas_on_path()
done
echo "Root names"
getfattr --absolute-names -Rh -m xfsroot $_path |\
getfattr --absolute-names -Rh -m trusted $_path |\
perl -wn -e '
if (m/^# file: (\S+)/) { $file = $1 }
elsif (m/^xfsroot\.(\w+)/) { print $file, " ",$1,"\n" }' |\
elsif (m/^trusted\.(\w+)/) { print $file, " ",$1,"\n" }' |\
sort |\
while read file ea_name; do
attr -R -g $ea_name $file