diff --git a/test/integration-test-main.sh b/test/integration-test-main.sh index d0539b6..d63c846 100755 --- a/test/integration-test-main.sh +++ b/test/integration-test-main.sh @@ -314,6 +314,27 @@ ls 'special*' 2>&1 | grep -q 'No such file or directory' ls 'special~' 2>&1 | grep -q 'No such file or directory' ls 'specialĀµ' 2>&1 | grep -q 'No such file or directory' +########################################################## +# Testing extended attributes +########################################################## + +rm -f $TEST_TEXT_FILE +touch $TEST_TEXT_FILE + +# set value +setfattr -n key1 -v value1 $TEST_TEXT_FILE +getfattr -n key1 --only-values $TEST_TEXT_FILE | grep -q '^value1$' + +# append value +setfattr -n key2 -v value2 $TEST_TEXT_FILE +getfattr -n key1 --only-values $TEST_TEXT_FILE | grep -q '^value1$' +getfattr -n key2 --only-values $TEST_TEXT_FILE | grep -q '^value2$' + +# remove value +setfattr -x key1 $TEST_TEXT_FILE +! getfattr -n key1 --only-values $TEST_TEXT_FILE +getfattr -n key2 --only-values $TEST_TEXT_FILE | grep -q '^value2$' + ##################################################################### # Tests are finished #####################################################################