summaryrefslogtreecommitdiff
path: root/tests/ln/backup-1
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>2007-09-08 09:35:04 +0200
committerJim Meyering <jim@meyering.net>2007-09-15 08:40:38 +0200
commit7455bf9432c0ae3664803695ddcb27613d20ca8e (patch)
treeeaf01893f2708517cc3191bc2fbd5999dd69b1e5 /tests/ln/backup-1
parent74ffe86ed05cd6bab4b9d31d63cf94637f867c04 (diff)
downloadcoreutils-7455bf9432c0ae3664803695ddcb27613d20ca8e.tar.xz
Convert tests/ln/, too.
Diffstat (limited to 'tests/ln/backup-1')
-rwxr-xr-xtests/ln/backup-114
1 files changed, 4 insertions, 10 deletions
diff --git a/tests/ln/backup-1 b/tests/ln/backup-1
index 9a4b65d47..05041fe21 100755
--- a/tests/ln/backup-1
+++ b/tests/ln/backup-1
@@ -2,7 +2,7 @@
# Try to create a symlink with backup where the destination file exists
# and the backup file name is a hard link to the destination file.
-# Copyright (C) 1999 Free Software Foundation, Inc.
+# Copyright (C) 1999, 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
@@ -24,17 +24,11 @@ if test "$VERBOSE" = yes; then
ln --version
fi
-trap "rm -rf a b b~" 0 1 2 3 15
+. $srcdir/../test-lib.sh
-framework_failure=0
-touch a b || framework_failure=1
-
-if test $framework_failure = 1; then
- echo 'failure in testing framework'
- exit 1
-fi
+touch a b || framework_failure
ln b b~ || fail=1
ln -f --b=simple a b || fail=1
-exit $fail
+(exit $fail); exit $fail