summaryrefslogtreecommitdiff
path: root/tests/cp
diff options
context:
space:
mode:
authorJim Meyering <meyering@redhat.com>2012-01-07 17:47:58 +0100
committerJim Meyering <meyering@redhat.com>2012-01-09 21:50:08 +0100
commitdd0e4c5621ca2fa9255aef4eee0e7cf41cd335d2 (patch)
tree5194ff517669cfb08a3ba329658b45870ab063bd /tests/cp
parent50610144b02763f5dd5f6198ceceb88c27c393aa (diff)
downloadcoreutils-dd0e4c5621ca2fa9255aef4eee0e7cf41cd335d2.tar.xz
tests: change `...' to '...' on lines not matching /[=\$]/
Exempt lines with '$' or '=', since those are prone to improper conversion. Run this: git grep -l "\`[^']*'" tests \ |xargs perl -pi -e '/[=\$]/ and next;s/\`([^'\''"]*?'\'')/'\''$1/g'
Diffstat (limited to 'tests/cp')
-rwxr-xr-xtests/cp/backup-is-src2
-rwxr-xr-xtests/cp/cp-a-selinux2
-rwxr-xr-xtests/cp/cp-deref2
-rwxr-xr-xtests/cp/cp-mv-backup2
-rwxr-xr-xtests/cp/cp-mv-enotsup-xattr2
-rwxr-xr-xtests/cp/fail-perm4
-rwxr-xr-xtests/cp/fiemap-empty2
-rwxr-xr-xtests/cp/fiemap-perf2
-rwxr-xr-xtests/cp/into-self14
-rwxr-xr-xtests/cp/link-preserve2
-rwxr-xr-xtests/cp/no-deref-link12
-rwxr-xr-xtests/cp/no-deref-link22
-rwxr-xr-xtests/cp/no-deref-link32
-rwxr-xr-xtests/cp/perm2
-rwxr-xr-xtests/cp/r-vs-symlink2
-rwxr-xr-xtests/cp/same-file54
-rwxr-xr-xtests/cp/slink-2-slink2
-rwxr-xr-xtests/cp/special-bits2
-rwxr-xr-xtests/cp/symlink-slash2
19 files changed, 52 insertions, 52 deletions
diff --git a/tests/cp/backup-is-src b/tests/cp/backup-is-src
index fc8dbf3c4..9fa7ec6e2 100755
--- a/tests/cp/backup-is-src
+++ b/tests/cp/backup-is-src
@@ -28,7 +28,7 @@ cp --b=simple a~ a > out 2>&1 && fail=1
sed "s,cp:,XXX:," out > out2
cat > exp <<\EOF
-XXX: backing up `a' would destroy source; `a~' not copied
+XXX: backing up 'a' would destroy source; 'a~' not copied
EOF
compare exp out2 || fail=1
diff --git a/tests/cp/cp-a-selinux b/tests/cp/cp-a-selinux
index be8465645..11758170d 100755
--- a/tests/cp/cp-a-selinux
+++ b/tests/cp/cp-a-selinux
@@ -83,7 +83,7 @@ grep "Operation not supported" err && fail=1
# to the file type.
# Note: this test could also be run by a regular (non-root) user in an
# NFS mounted directory. When doing that, I get this diagnostic:
-# cp: failed to set the security context of `g' to `system_u:object_r:nfs_t': \
+# cp: failed to set the security context of 'g' to 'system_u:object_r:nfs_t': \
# Operation not supported
cat <<\EOF > exp || framework_failure_
cp: failed to set the security context of
diff --git a/tests/cp/cp-deref b/tests/cp/cp-deref
index 290ee4092..08a1485f9 100755
--- a/tests/cp/cp-deref
+++ b/tests/cp/cp-deref
@@ -26,7 +26,7 @@ ln -s ../c b || framework_failure_
# Before coreutils-5.94, the following would fail with this message:
-# cp: will not create hard link `d/b/c' to directory `d/a/c'
+# cp: will not create hard link 'd/b/c' to directory 'd/a/c'
cp -RL a b d || fail=1
test -d a/c || fail=1
test -d b/c || fail=1
diff --git a/tests/cp/cp-mv-backup b/tests/cp/cp-mv-backup
index 5a122294e..66cc74bf1 100755
--- a/tests/cp/cp-mv-backup
+++ b/tests/cp/cp-mv-backup
@@ -22,7 +22,7 @@ print_ver_ cp
umask 022
# Be careful to close $actual before removing the containing directory.
-# Use `1>&2' rather than `1<&-' since the latter appears not to work
+# Use '1>&2' rather than '1<&-' since the latter appears not to work
# with /bin/sh from powerpc-ibm-aix4.2.0.0.
actual=actual
diff --git a/tests/cp/cp-mv-enotsup-xattr b/tests/cp/cp-mv-enotsup-xattr
index d9b373ff2..76ede2e3e 100755
--- a/tests/cp/cp-mv-enotsup-xattr
+++ b/tests/cp/cp-mv-enotsup-xattr
@@ -89,7 +89,7 @@ rm -f err noxattr/a
cp -a --preserve=xattr xattr/a noxattr/ 2>err && fail=1
if grep '^#define USE_XATTR 1' $CONFIG_HEADER > /dev/null; then
cat <<\EOF > exp
-cp: setting attributes for `noxattr/a': Operation not supported
+cp: setting attributes for 'noxattr/a': Operation not supported
EOF
else
cat <<\EOF > exp
diff --git a/tests/cp/fail-perm b/tests/cp/fail-perm
index c7c89942f..2b6133cd0 100755
--- a/tests/cp/fail-perm
+++ b/tests/cp/fail-perm
@@ -29,7 +29,7 @@ chmod u=rx,go=,-st D || framework_failure_
# This is expected to exit non-zero, because it can't read D/a.
cp -pR D DD > /dev/null 2>&1 && fail=1
-# Permissions on DD must be `dr-x------'
+# Permissions on DD must be 'dr-x------'
mode=`ls -ld DD|cut -b-10`
test "$mode" = dr-x------ || fail=1
@@ -38,7 +38,7 @@ chmod 0 D
ln -s D/D symlink
touch F
cat > exp <<\EOF
-cp: accessing `symlink': Permission denied
+cp: accessing 'symlink': Permission denied
EOF
cp F symlink 2> out && fail=1
diff --git a/tests/cp/fiemap-empty b/tests/cp/fiemap-empty
index 878831d2e..951d8e062 100755
--- a/tests/cp/fiemap-empty
+++ b/tests/cp/fiemap-empty
@@ -48,7 +48,7 @@ fallocate -l 600MiB space.test ||
# Disable this test on old BTRFS (e.g. Fedora 14)
# which reports ordinary extents for unwritten ones.
-filefrag space.test || skip_ 'the `filefrag` utility is missing'
+filefrag space.test || skip_ 'the 'filefrag` utility is missing'
filefrag -v space.test | grep -F 'unwritten' > /dev/null ||
skip_ 'this file system does not report empty extents as "unwritten"'
diff --git a/tests/cp/fiemap-perf b/tests/cp/fiemap-perf
index 33bb818d2..3addfe1b2 100755
--- a/tests/cp/fiemap-perf
+++ b/tests/cp/fiemap-perf
@@ -34,7 +34,7 @@ timeout 10 truncate -s1T f || framework_failure_
# Disable this test on old BTRFS (e.g. Fedora 14)
# which reports (unwritten) extents for holes.
-filefrag f || skip_ 'the `filefrag` utility is missing'
+filefrag f || skip_ 'the 'filefrag` utility is missing'
filefrag f | grep -F ': 0 extents found' > /dev/null ||
skip_ 'this file system reports extents for holes'
diff --git a/tests/cp/into-self b/tests/cp/into-self
index 792e659f8..67cec7f95 100755
--- a/tests/cp/into-self
+++ b/tests/cp/into-self
@@ -16,10 +16,10 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
-# In 4.0.35 and earlier, `mkdir dir && cp -R dir dir' would produce this:
-# cp: won't create hard link `dir/dir/dir' to directory `'
+# In 4.0.35 and earlier, 'mkdir dir && cp -R dir dir' would produce this:
+# cp: won't create hard link 'dir/dir/dir' to directory ''
# Now it gives this:
-# cp: can't copy a directory `dir' into itself `dir/dir'
+# cp: can't copy a directory 'dir' into itself 'dir/dir'
. "${srcdir=.}/init.sh"; path_prepend_ ../src
print_ver_ cp
@@ -41,13 +41,13 @@ cp -rl a dir dir 2>> out && fail=1
echo 4 >> out
cat > exp <<\EOF
-cp: cannot copy a directory, `dir', into itself, `dir/dir'
+cp: cannot copy a directory, 'dir', into itself, 'dir/dir'
1
-cp: cannot copy a directory, `dir', into itself, `dir/dir'
+cp: cannot copy a directory, 'dir', into itself, 'dir/dir'
2
-cp: cannot copy a directory, `dir', into itself, `dir/dir'
+cp: cannot copy a directory, 'dir', into itself, 'dir/dir'
3
-cp: cannot copy a directory, `dir', into itself, `dir/dir'
+cp: cannot copy a directory, 'dir', into itself, 'dir/dir'
4
EOF
#'
diff --git a/tests/cp/link-preserve b/tests/cp/link-preserve
index 5b84f3ca8..243cf3721 100755
--- a/tests/cp/link-preserve
+++ b/tests/cp/link-preserve
@@ -1,5 +1,5 @@
#!/bin/sh
-# ensure that `cp -d' preserves hard-links between command line arguments
+# ensure that 'cp -d' preserves hard-links between command line arguments
# ensure that --preserve=links works with -RH and -RL
# Copyright (C) 2001-2002, 2004, 2006-2012 Free Software Foundation, Inc.
diff --git a/tests/cp/no-deref-link1 b/tests/cp/no-deref-link1
index 100bf3c17..677c284cf 100755
--- a/tests/cp/no-deref-link1
+++ b/tests/cp/no-deref-link1
@@ -29,7 +29,7 @@ cd ..
# It should fail with a message something like this:
-# ./cp: `a/foo' and `b/foo' are the same file
+# ./cp: 'a/foo' and 'b/foo' are the same file
cp -d a/foo b 2>/dev/null
# Fail this test if the exit status is not 1
diff --git a/tests/cp/no-deref-link2 b/tests/cp/no-deref-link2
index df2c70fc1..33fc43187 100755
--- a/tests/cp/no-deref-link2
+++ b/tests/cp/no-deref-link2
@@ -29,7 +29,7 @@ cd ..
# It should fail with a message something like this:
-# cp: `a' and `b/foo' are the same file
+# cp: 'a' and 'b/foo' are the same file
cp -d a b 2>/dev/null
# Fail this test if the exit status is not 1
diff --git a/tests/cp/no-deref-link3 b/tests/cp/no-deref-link3
index 052be6dd1..6ea56349d 100755
--- a/tests/cp/no-deref-link3
+++ b/tests/cp/no-deref-link3
@@ -26,7 +26,7 @@ ln -s a b
# It should fail with a message something like this:
-# cp: `a' and `b' are the same file
+# cp: 'a' and 'b' are the same file
cp -d a b 2>/dev/null
# Fail this test if the exit status is not 1
diff --git a/tests/cp/perm b/tests/cp/perm
index 2dd3ae571..7a03400b0 100755
--- a/tests/cp/perm
+++ b/tests/cp/perm
@@ -24,7 +24,7 @@ very_expensive_
umask 037
-# Now, try it with `mv', with combinations of --force, no-f and
+# Now, try it with 'mv', with combinations of --force, no-f and
# existing-destination and not.
for u in 31 37 2; do
echo umask: $u
diff --git a/tests/cp/r-vs-symlink b/tests/cp/r-vs-symlink
index 13c58f64f..36bf3a5c3 100755
--- a/tests/cp/r-vs-symlink
+++ b/tests/cp/r-vs-symlink
@@ -18,7 +18,7 @@
# Restored old behavior (whereby cp -r preserves symlinks) in 4.1.6,
# though now such usage evokes a warning:
-# cp: `slink': WARNING: using -r to copy symbolic links is not portable
+# cp: 'slink': WARNING: using -r to copy symbolic links is not portable
. "${srcdir=.}/init.sh"; path_prepend_ ../src
print_ver_ cp
diff --git a/tests/cp/same-file b/tests/cp/same-file
index dad7068ff..440f342e3 100755
--- a/tests/cp/same-file
+++ b/tests/cp/same-file
@@ -20,7 +20,7 @@
. "${srcdir=.}/init.sh"; path_prepend_ ../src
print_ver_ cp
-# Unset CDPATH. Otherwise, output from the `cd dir' command
+# Unset CDPATH. Otherwise, output from the 'cd dir' command
# can make this test fail.
(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
@@ -128,16 +128,16 @@ for args in 'foo symlink' 'symlink foo' 'foo foo' 'sl1 sl2' 'foo hardlink'; do
done
cat <<\EOF | sed "$remove_these_sed" > expected
-1 [cp: `foo' and `symlink' are the same file] (foo symlink -> foo)
-1 -d [cp: `foo' and `symlink' are the same file] (foo symlink -> foo)
-1 -f [cp: `foo' and `symlink' are the same file] (foo symlink -> foo)
-1 -df [cp: `foo' and `symlink' are the same file] (foo symlink -> foo)
+1 [cp: 'foo' and 'symlink' are the same file] (foo symlink -> foo)
+1 -d [cp: 'foo' and 'symlink' are the same file] (foo symlink -> foo)
+1 -f [cp: 'foo' and 'symlink' are the same file] (foo symlink -> foo)
+1 -df [cp: 'foo' and 'symlink' are the same file] (foo symlink -> foo)
0 --rem (foo symlink)
0 -b (foo symlink symlink.~1~ -> foo)
0 -bd (foo symlink symlink.~1~ -> foo)
0 -bf (foo symlink symlink.~1~ -> foo)
0 -bdf (foo symlink symlink.~1~ -> foo)
-1 -l [cp: cannot create hard link `symlink' to `foo'] (foo symlink -> foo)
+1 -l [cp: cannot create hard link 'symlink' to 'foo'] (foo symlink -> foo)
0 -dl (foo symlink -> foo)
0 -fl (foo symlink)
0 -dfl (foo symlink)
@@ -146,14 +146,14 @@ cat <<\EOF | sed "$remove_these_sed" > expected
0 -bfl (foo symlink symlink.~1~ -> foo)
0 -bdfl (foo symlink symlink.~1~ -> foo)
-1 [cp: `symlink' and `foo' are the same file] (foo symlink -> foo)
-1 -d [cp: `symlink' and `foo' are the same file] (foo symlink -> foo)
-1 -f [cp: `symlink' and `foo' are the same file] (foo symlink -> foo)
-1 -df [cp: `symlink' and `foo' are the same file] (foo symlink -> foo)
-1 --rem [cp: `symlink' and `foo' are the same file] (foo symlink -> foo)
-1 -b [cp: `symlink' and `foo' are the same file] (foo symlink -> foo)
+1 [cp: 'symlink' and 'foo' are the same file] (foo symlink -> foo)
+1 -d [cp: 'symlink' and 'foo' are the same file] (foo symlink -> foo)
+1 -f [cp: 'symlink' and 'foo' are the same file] (foo symlink -> foo)
+1 -df [cp: 'symlink' and 'foo' are the same file] (foo symlink -> foo)
+1 --rem [cp: 'symlink' and 'foo' are the same file] (foo symlink -> foo)
+1 -b [cp: 'symlink' and 'foo' are the same file] (foo symlink -> foo)
0 -bd (foo -> foo foo.~1~ symlink -> foo) symlink-loop symlink-loop
-1 -bf [cp: `symlink' and `foo' are the same file] (foo symlink -> foo)
+1 -bf [cp: 'symlink' and 'foo' are the same file] (foo symlink -> foo)
0 -bdf (foo -> foo foo.~1~ symlink -> foo) symlink-loop symlink-loop
0 -l (foo symlink -> foo)
0 -dl (foo symlink -> foo)
@@ -161,13 +161,13 @@ cat <<\EOF | sed "$remove_these_sed" > expected
0 -bl (foo symlink -> foo)
0 -bfl (foo symlink -> foo)
-1 [cp: `foo' and `foo' are the same file] (foo)
-1 -d [cp: `foo' and `foo' are the same file] (foo)
-1 -f [cp: `foo' and `foo' are the same file] (foo)
-1 -df [cp: `foo' and `foo' are the same file] (foo)
-1 --rem [cp: `foo' and `foo' are the same file] (foo)
-1 -b [cp: `foo' and `foo' are the same file] (foo)
-1 -bd [cp: `foo' and `foo' are the same file] (foo)
+1 [cp: 'foo' and 'foo' are the same file] (foo)
+1 -d [cp: 'foo' and 'foo' are the same file] (foo)
+1 -f [cp: 'foo' and 'foo' are the same file] (foo)
+1 -df [cp: 'foo' and 'foo' are the same file] (foo)
+1 --rem [cp: 'foo' and 'foo' are the same file] (foo)
+1 -b [cp: 'foo' and 'foo' are the same file] (foo)
+1 -bd [cp: 'foo' and 'foo' are the same file] (foo)
0 -bf (foo foo.~1~)
0 -bdf (foo foo.~1~)
0 -l (foo)
@@ -179,24 +179,24 @@ cat <<\EOF | sed "$remove_these_sed" > expected
0 -bfl (foo foo.~1~)
0 -bdfl (foo foo.~1~)
-1 [cp: `sl1' and `sl2' are the same file] (foo sl1 -> foo sl2 -> foo)
+1 [cp: 'sl1' and 'sl2' are the same file] (foo sl1 -> foo sl2 -> foo)
0 -d (foo sl1 -> foo sl2 -> foo)
-1 -f [cp: `sl1' and `sl2' are the same file] (foo sl1 -> foo sl2 -> foo)
+1 -f [cp: 'sl1' and 'sl2' are the same file] (foo sl1 -> foo sl2 -> foo)
0 -df (foo sl1 -> foo sl2 -> foo)
0 --rem (foo sl1 -> foo sl2)
0 -b (foo sl1 -> foo sl2 sl2.~1~ -> foo)
0 -bd (foo sl1 -> foo sl2 -> foo sl2.~1~ -> foo)
0 -bf (foo sl1 -> foo sl2 sl2.~1~ -> foo)
0 -bdf (foo sl1 -> foo sl2 -> foo sl2.~1~ -> foo)
-1 -l [cp: cannot create hard link `sl2' to `sl1'] (foo sl1 -> foo sl2 -> foo)
+1 -l [cp: cannot create hard link 'sl2' to 'sl1'] (foo sl1 -> foo sl2 -> foo)
0 -fl (foo sl1 -> foo sl2 -> foo)
0 -bl (foo sl1 -> foo sl2 -> foo sl2.~1~ -> foo)
0 -bfl (foo sl1 -> foo sl2 -> foo sl2.~1~ -> foo)
-1 [cp: `foo' and `hardlink' are the same file] (foo hardlink)
-1 -d [cp: `foo' and `hardlink' are the same file] (foo hardlink)
-1 -f [cp: `foo' and `hardlink' are the same file] (foo hardlink)
-1 -df [cp: `foo' and `hardlink' are the same file] (foo hardlink)
+1 [cp: 'foo' and 'hardlink' are the same file] (foo hardlink)
+1 -d [cp: 'foo' and 'hardlink' are the same file] (foo hardlink)
+1 -f [cp: 'foo' and 'hardlink' are the same file] (foo hardlink)
+1 -df [cp: 'foo' and 'hardlink' are the same file] (foo hardlink)
0 --rem (foo hardlink)
0 -b (foo hardlink hardlink.~1~)
0 -bd (foo hardlink hardlink.~1~)
diff --git a/tests/cp/slink-2-slink b/tests/cp/slink-2-slink
index 10207db74..8542db1bd 100755
--- a/tests/cp/slink-2-slink
+++ b/tests/cp/slink-2-slink
@@ -1,5 +1,5 @@
#!/bin/sh
-# `test cp --update A B' where A and B are both symlinks that point
+# 'test cp --update A B' where A and B are both symlinks that point
# to the same file
# Copyright (C) 2000, 2002, 2004, 2006-2012 Free Software Foundation, Inc.
diff --git a/tests/cp/special-bits b/tests/cp/special-bits
index c3de42612..362401156 100755
--- a/tests/cp/special-bits
+++ b/tests/cp/special-bits
@@ -1,5 +1,5 @@
#!/bin/sh
-# make sure `cp -p' preserves special bits
+# make sure 'cp -p' preserves special bits
# This works only when run as root.
# Copyright (C) 2000-2002, 2004, 2006-2012 Free Software Foundation, Inc.
diff --git a/tests/cp/symlink-slash b/tests/cp/symlink-slash
index d90809574..eeaf97cdf 100755
--- a/tests/cp/symlink-slash
+++ b/tests/cp/symlink-slash
@@ -26,7 +26,7 @@ ln -s dir symlink || framework_failure_
cp -dR symlink/ s || fail=1
set `ls -l s`
-# Prior to fileutils-4.0q, the following would have output ...`s -> dir'
+# Prior to fileutils-4.0q, the following would have output ...'s -> dir'
# because the trailing slash was removed unconditionally (now you have to
# use the new --strip-trailing-slash option) causing cp to reproduce the
# symlink. Now, the trailing slash is interpreted by the stat library