summaryrefslogtreecommitdiff
path: root/tests/du/two-args
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>2000-09-30 08:32:55 +0000
committerJim Meyering <jim@meyering.net>2000-09-30 08:32:55 +0000
commitd7232f8ca7fec756ad32cce7d771d41f4bede42f (patch)
treefb7914c5f77729e6a0808e4c040db858ea956b2d /tests/du/two-args
parentc217428f3918ee2b9405639b88b1a92697e5d667 (diff)
downloadcoreutils-d7232f8ca7fec756ad32cce7d771d41f4bede42f.tar.xz
Update to use newer template.
Diffstat (limited to 'tests/du/two-args')
-rwxr-xr-xtests/du/two-args16
1 files changed, 13 insertions, 3 deletions
diff --git a/tests/du/two-args b/tests/du/two-args
index 6de6d0fe8..27c78968e 100755
--- a/tests/du/two-args
+++ b/tests/du/two-args
@@ -7,9 +7,19 @@ if test "$VERBOSE" = yes; then
du --version
fi
+pwd=`pwd`
tmp=du2-$$
-trap 'status=$?; rm -rf $tmp && exit $status' 0
-trap 'exit $?' 1 2 13 15
+trap 'status=$?; cd $pwd; rm -rf $tmp && exit $status' 0
+trap '(exit $?); exit' 1 2 13 15
+
+framework_failure=0
+mkdir $tmp || framework_failure=1
+cd $tmp || framework_failure=1
+
+if test $framework_failure = 1; then
+ echo 'failure in testing framework'
+ (exit 1); exit
+fi
mkdir -p $tmp/1 $tmp/2
@@ -21,4 +31,4 @@ du $tmp/1 $tmp/2 > /dev/null || fail=1
du . $tmp > /dev/null || fail=1
du .. $tmp > /dev/null || fail=1
-exit $fail
+(exit $fail); exit