From 7172a637b75f3fab4514c917ebdca20ddf69e6ea Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Tue, 24 Aug 2010 10:46:23 -0700 Subject: [PATCH] qa: snaptest-xattrwb.sh --- .../{snaptest-xattrflush.sh => snaptest-xattrwb.sh} | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) rename qa/workunits/{snaptest-xattrflush.sh => snaptest-xattrwb.sh} (53%) diff --git a/qa/workunits/snaptest-xattrflush.sh b/qa/workunits/snaptest-xattrwb.sh similarity index 53% rename from qa/workunits/snaptest-xattrflush.sh rename to qa/workunits/snaptest-xattrwb.sh index 4545638c2120..52973cc31fc1 100755 --- a/qa/workunits/snaptest-xattrflush.sh +++ b/qa/workunits/snaptest-xattrwb.sh @@ -2,6 +2,15 @@ set -e +echo "testing simple xattr wb" +touch x +setfattr -n user.foo x +mkdir .snap/s1 +getfattr -n user.foo .snap/s1/x | grep user.foo +rm x +rmdir .snap/s1 + +echo "testing wb with pre-wb server cow" mkdir a mkdir a/b mkdir a/b/c @@ -11,9 +20,7 @@ mkdir a/.snap/s mkdir a/b/cc # b now has been cowed on the server, but we still have dirty xattr caps getfattr -n user.foo a/b # there they are... -r=`getfattr -n user.foo a/.snap/s/b` # should be there, too! -echo $r -[ -z "$r" ] && echo "didn't find user.foo xattr in snapped version" && false +getfattr -n user.foo a/.snap/s/b | grep user.foo # should be there, too! # ok, clean up rmdir a/.snap/s -- 2.47.3