* tests/cp/acl: Support USE_ACL not being defined.
* tests/mv/acl: Likewise. Also fix typo in skip message.
* tests/cp/preserve-slink-time: Support HAVE_UTIMENSAT being 0.
* tests/touch/no-dereference: Likewise.
* tests/ls/capability: Normalize so 1 is not required to be last char.
require_acl_
# Skip this test if cp was built without ACL support:
-grep '^#define USE_ACL 0' $CONFIG_HEADER > /dev/null &&
+grep '^#define USE_ACL 1' $CONFIG_HEADER > /dev/null ||
skip_test_ "insufficient ACL support"
mkdir -p a b || framework_failure
. $srcdir/test-lib.sh
-grep '^#define HAVE_UTIMENSAT' "$CONFIG_HEADER" > /dev/null ||
-grep '^#define HAVE_LUTIMES' "$CONFIG_HEADER" > /dev/null ||
+grep '^#define HAVE_UTIMENSAT 1' "$CONFIG_HEADER" > /dev/null ||
+grep '^#define HAVE_LUTIMES 1' "$CONFIG_HEADER" > /dev/null ||
skip_test_ 'this system lacks the utimensat function'
ln -s no-such dangle || framework_failure
. $srcdir/test-lib.sh
require_root_
-grep '^#define HAVE_CAP 1$' $CONFIG_HEADER > /dev/null \
+grep '^#define HAVE_CAP 1' $CONFIG_HEADER > /dev/null \
|| skip_test_ "configured without libcap support"
(setcap --help) 2>&1 |grep 'usage: setcap' > /dev/null \
require_acl_
# Skip this test if cp was built without ACL support:
-grep '^#define USE_ACL 0' $CONFIG_HEADER > /dev/null &&
+grep '^#define USE_ACL 1' $CONFIG_HEADER > /dev/null ||
skip_test_ "insufficient ACL support"
cleanup_() { rm -rf "$other_partition_tmpdir"; }
acl1=`getfacl file` || skip_partition=.
test $skip_partition != none &&
- skip_test_ "'$skip' is not on a suitable file system for this test"
+ skip_test_ "'$skip_partition' is not on a suitable file system for this test"
# move the access acl of a file
mv file "$other_partition_tmpdir" || fail=1
test -f nowhere && fail=1
# The remaining tests of -h require kernel support for changing symlink times.
-grep '^#define HAVE_UTIMENSAT' "$CONFIG_HEADER" > /dev/null ||
-grep '^#define HAVE_LUTIMES' "$CONFIG_HEADER" > /dev/null ||
+grep '^#define HAVE_UTIMENSAT 1' "$CONFIG_HEADER" > /dev/null ||
+grep '^#define HAVE_LUTIMES 1' "$CONFIG_HEADER" > /dev/null ||
skip_test_ 'this system lacks the utimensat function'
# Changing time of dangling symlink is okay.