diff options
Diffstat (limited to 'tests/ls/recursive')
-rwxr-xr-x | tests/ls/recursive | 28 |
1 files changed, 6 insertions, 22 deletions
diff --git a/tests/ls/recursive b/tests/ls/recursive index 6e4cedd88..8aff3ed7e 100755 --- a/tests/ls/recursive +++ b/tests/ls/recursive @@ -2,7 +2,7 @@ # 4.1.1 and 4.1.2 had a bug whereby some recursive listings # didn't include a blank line between per-directory groups of files. -# Copyright (C) 2001, 2002, 2004, 2006 Free Software Foundation, Inc. +# Copyright (C) 2001, 2002, 2004, 2006-2007 Free Software Foundation, Inc. # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -22,24 +22,10 @@ if test "$VERBOSE" = yes; then ls --version fi -. $srcdir/../envvar-check +. $srcdir/../test-lib.sh -pwd=`pwd` -tmp=recursive.$$ -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 - -mkdir x y a b c a/1 a/2 a/3 || framework_failure=1 -touch f a/1/I a/1/II || framework_failure=1 - -if test $framework_failure = 1; then - echo "$0: failure in testing framework" 1>&2 - (exit 1); exit 1 -fi +mkdir x y a b c a/1 a/2 a/3 || framework_failure +touch f a/1/I a/1/II || framework_failure fail=0 @@ -64,8 +50,7 @@ b: c: EOF -cmp out exp || fail=1 -test $fail = 1 && diff out exp 2> /dev/null +compare out exp || fail=1 rm -rf out exp ls -R1 x y f > out || fail=1 @@ -77,7 +62,6 @@ x: y: EOF -cmp out exp || fail=1 -test $fail = 1 && diff out exp 2> /dev/null +compare out exp || fail=1 (exit $fail); exit $fail |