summaryrefslogtreecommitdiff
path: root/tests/mv
diff options
context:
space:
mode:
Diffstat (limited to 'tests/mv')
-rwxr-xr-xtests/mv/part-symlink122
1 files changed, 61 insertions, 61 deletions
diff --git a/tests/mv/part-symlink b/tests/mv/part-symlink
index 78da70a39..71788b905 100755
--- a/tests/mv/part-symlink
+++ b/tests/mv/part-symlink
@@ -83,67 +83,67 @@ for copy in cp mv; do
actual_args=`eval echo $actual_args`
(
- (
- # echo 1>&2 cp $options $args
- $copy $options $actual_args 2>.err
- copy_status=$?
- echo $copy_status $copy $options $args
-
- # Normalize the program name in the error output,
- # remove any site-dependent part of other-partition file name,
- # and put brackets around the output.
- test -s .err && {
- echo '[' | tr -d '\n'
- sed 's/^[^:][^:]*\(..\):/\1:/;s,'$other_partition_tmpdir/,, .err
- echo ']' | tr -d '\n'
- }
- # Strip off all but the file names.
- # Remove any site-dependent part of each file name.
- ls=`ls -gG --ignore=.err . \
- | sed \
- -e '/^total /d' \
- -e s,$other_partition_tmpdir/,, \
- -e "s,$pwd_tmp/,," \
- -e 's/^[^ ]* *[^ ]* *[^ ]* *[^ ]* *[^ ]* *[^ ]* *//'`
- ls2=`cd $other_partition_tmpdir && ls -gG --ignore=.err . \
- | sed \
- -e '/^total /d' \
- -e s,$other_partition_tmpdir/,, \
- -e "s,$pwd_tmp/,," \
- -e 's/^[^ ]* *[^ ]* *[^ ]* *[^ ]* *[^ ]* *[^ ]* *//'`
- echo "($ls) ($ls2)"
-
- # If the command failed, then it must not have changed the files.
- if test $copy_status != 0; then
- for f in $actual_args; do
- test -f $f ||
- { echo "$copy FAILED but removed $f"; continue; }
- case "`cat $f`" in
- "$contents") ;;
- *) echo "$copy FAILED but modified $f";;
- esac
- done
- fi
-
- if test $copy = cp; then
- # Make sure the original is unchanged and that
- # the destination is a copy.
- for f in $actual_args; do
- if test -f $f; then
- if test $copy_status != 0; then
- test
- fi
- case "`cat $f`" in
- "$contents") ;;
- *) echo $copy FAILED;;
- esac
- else
- echo symlink-loop
- fi
- done
- fi
- ) | tr '\n' ' '
- echo
+ (
+ # echo 1>&2 cp $options $args
+ $copy $options $actual_args 2>.err
+ copy_status=$?
+ echo $copy_status $copy $options $args
+
+ # Normalize the program name in the error output,
+ # remove any site-dependent part of other-partition file name,
+ # and put brackets around the output.
+ test -s .err && {
+ echo '[' | tr -d '\n'
+ sed 's/^[^:][^:]*\(..\):/\1:/;s,'$other_partition_tmpdir/,, .err
+ echo ']' | tr -d '\n'
+ }
+ # Strip off all but the file names.
+ # Remove any site-dependent part of each file name.
+ ls=`ls -gG --ignore=.err . \
+ | sed \
+ -e '/^total /d' \
+ -e s,$other_partition_tmpdir/,, \
+ -e "s,$pwd_tmp/,," \
+ -e 's/^[^ ]* *[^ ]* *[^ ]* *[^ ]* *[^ ]* *[^ ]* *//'`
+ ls2=`cd $other_partition_tmpdir && ls -gG --ignore=.err . \
+ | sed \
+ -e '/^total /d' \
+ -e s,$other_partition_tmpdir/,, \
+ -e "s,$pwd_tmp/,," \
+ -e 's/^[^ ]* *[^ ]* *[^ ]* *[^ ]* *[^ ]* *[^ ]* *//'`
+ echo "($ls) ($ls2)"
+
+ # If the command failed, then it must not have changed the files.
+ if test $copy_status != 0; then
+ for f in $actual_args; do
+ test -f $f ||
+ { echo "$copy FAILED but removed $f"; continue; }
+ case "`cat $f`" in
+ "$contents") ;;
+ *) echo "$copy FAILED but modified $f";;
+ esac
+ done
+ fi
+
+ if test $copy = cp; then
+ # Make sure the original is unchanged and that
+ # the destination is a copy.
+ for f in $actual_args; do
+ if test -f $f; then
+ if test $copy_status != 0; then
+ test
+ fi
+ case "`cat $f`" in
+ "$contents") ;;
+ *) echo $copy FAILED;;
+ esac
+ else
+ echo symlink-loop
+ fi
+ done
+ fi
+ ) | tr '\n' ' '
+ echo
) | sed 's/ *$//'
cd ..
done