summaryrefslogtreecommitdiff
path: root/tests/chmod
diff options
context:
space:
mode:
authorJim Meyering <meyering@redhat.com>2008-09-07 10:31:27 +0200
committerJim Meyering <meyering@redhat.com>2008-09-10 13:20:10 +0200
commit68561594ca022703e255b3ef5686f176317e5fd4 (patch)
tree2bb17f465ad51bb9bf212b871a95b877e558d2e0 /tests/chmod
parent22e5102f1961c5552d20c3791cbc99b6b001e83f (diff)
downloadcoreutils-68561594ca022703e255b3ef5686f176317e5fd4.tar.xz
tests: use "Exit $fail", not (exit $fail); exit $fail
* tests/test-lib.sh (Exit): New function by Ralf Wildenhues in automake http://git.sv.gnu.org/gitweb/?p=automake.git;a=commitdiff;h=20594c08f63 * tests/**: Convert all uses: This restrictive change converted the vast majority: git grep -l '^(exit \$fail); exit \$fail$' \ | xargs perl -pi -e 's/'^\(exit \$fail\); exit \$fail$/Exit \$fail/' And this did the rest, plus a few undesirable ones, so I manually backed out the changes to ChangeLog-* and build-aux/check.mk: git grep -l -E '\(exit [^)]+\); exit ' \ | xargs perl -pi -e 's/\(exit (.+?)\); exit \1/Exit $1/'
Diffstat (limited to 'tests/chmod')
-rwxr-xr-xtests/chmod/c-option2
-rwxr-xr-xtests/chmod/equal-x2
-rwxr-xr-xtests/chmod/equals2
-rwxr-xr-xtests/chmod/inaccessible2
-rwxr-xr-xtests/chmod/no-x2
-rwxr-xr-xtests/chmod/octal2
-rwxr-xr-xtests/chmod/setgid2
-rwxr-xr-xtests/chmod/thru-dangling2
-rwxr-xr-xtests/chmod/umask-x2
-rwxr-xr-xtests/chmod/usage2
10 files changed, 10 insertions, 10 deletions
diff --git a/tests/chmod/c-option b/tests/chmod/c-option
index 42da4b209..eb8530a52 100755
--- a/tests/chmod/c-option
+++ b/tests/chmod/c-option
@@ -42,4 +42,4 @@ case "`cat out`" in
*) fail=1 ;;
esac
-(exit $fail); exit $fail
+Exit $fail
diff --git a/tests/chmod/equal-x b/tests/chmod/equal-x
index 06c53c669..8d9dafe0f 100755
--- a/tests/chmod/equal-x
+++ b/tests/chmod/equal-x
@@ -36,4 +36,4 @@ for mode in =x =xX =Xx =x,=X =X,=x; do
esac
done
-(exit $fail); exit $fail
+Exit $fail
diff --git a/tests/chmod/equals b/tests/chmod/equals
index 9aca394c4..a748a606c 100755
--- a/tests/chmod/equals
+++ b/tests/chmod/equals
@@ -48,4 +48,4 @@ chmod a=,u=rwx,=u f || fail=1
actual_perms=`ls -l f|cut -b-10`
test "$actual_perms" = "-rwxr-x---" || fail=1
-(exit $fail); exit $fail
+Exit $fail
diff --git a/tests/chmod/inaccessible b/tests/chmod/inaccessible
index 70cdc9bff..6dd1b6a97 100755
--- a/tests/chmod/inaccessible
+++ b/tests/chmod/inaccessible
@@ -30,4 +30,4 @@ fail=0
chmod u+rwx d d/e || fail=1
-(exit $fail); exit $fail
+Exit $fail
diff --git a/tests/chmod/no-x b/tests/chmod/no-x
index b65295bd8..55bbe9896 100755
--- a/tests/chmod/no-x
+++ b/tests/chmod/no-x
@@ -59,4 +59,4 @@ chmod a-x . b 2> /dev/null && fail=1
# an abort (exit with status 134) on recent glibc-based systems.
test $? = 1 || fail=1
-(exit $fail); exit $fail
+Exit $fail
diff --git a/tests/chmod/octal b/tests/chmod/octal
index a7ddb4503..a86d0bd75 100755
--- a/tests/chmod/octal
+++ b/tests/chmod/octal
@@ -31,4 +31,4 @@ chmod 0-followed-by-anything . 2> /dev/null && fail=1
chmod 7-followed-by-anything . 2> /dev/null && fail=1
chmod 8 . 2> /dev/null && fail=1
-(exit $fail); exit $fail
+Exit $fail
diff --git a/tests/chmod/setgid b/tests/chmod/setgid
index 30e92f05a..d3cbbd368 100755
--- a/tests/chmod/setgid
+++ b/tests/chmod/setgid
@@ -50,4 +50,4 @@ chmod 755 d
case `ls -ld d` in drwxr-sr-x*);; *) fail=1;; esac
-(exit $fail); exit $fail
+Exit $fail
diff --git a/tests/chmod/thru-dangling b/tests/chmod/thru-dangling
index 055f9c59c..ecb6d3685 100755
--- a/tests/chmod/thru-dangling
+++ b/tests/chmod/thru-dangling
@@ -33,4 +33,4 @@ chmod 644 dangle 2> out && fail=1
echo "chmod: cannot operate on dangling symlink \`dangle'" > exp
compare out exp || fail=1
-(exit $fail); exit $fail
+Exit $fail
diff --git a/tests/chmod/umask-x b/tests/chmod/umask-x
index 13b6e9ac2..2526991e8 100755
--- a/tests/chmod/umask-x
+++ b/tests/chmod/umask-x
@@ -28,4 +28,4 @@ touch file
chmod 755 file
(umask 77 && chmod -x file) 2>/dev/null && fail=1
-(exit $fail); exit $fail
+Exit $fail
diff --git a/tests/chmod/usage b/tests/chmod/usage
index ba0ea7313..008cfee86 100755
--- a/tests/chmod/usage
+++ b/tests/chmod/usage
@@ -88,4 +88,4 @@ for case in $cases; do
esac
done
-(exit $fail); exit $fail
+Exit $fail