diff options
author | Jim Meyering <meyering@redhat.com> | 2012-01-07 17:47:58 +0100 |
---|---|---|
committer | Jim Meyering <meyering@redhat.com> | 2012-01-09 21:50:08 +0100 |
commit | dd0e4c5621ca2fa9255aef4eee0e7cf41cd335d2 (patch) | |
tree | 5194ff517669cfb08a3ba329658b45870ab063bd /tests/du | |
parent | 50610144b02763f5dd5f6198ceceb88c27c393aa (diff) | |
download | coreutils-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/du')
-rwxr-xr-x | tests/du/2g | 6 | ||||
-rwxr-xr-x | tests/du/8gb | 4 | ||||
-rwxr-xr-x | tests/du/deref | 2 | ||||
-rwxr-xr-x | tests/du/files0-from | 2 | ||||
-rwxr-xr-x | tests/du/inacc-dest | 6 | ||||
-rwxr-xr-x | tests/du/long-from-unreadable | 4 | ||||
-rwxr-xr-x | tests/du/long-sloop | 6 | ||||
-rwxr-xr-x | tests/du/no-x | 6 | ||||
-rwxr-xr-x | tests/du/restore-wd | 2 | ||||
-rwxr-xr-x | tests/du/slash | 2 | ||||
-rwxr-xr-x | tests/du/slink | 4 | ||||
-rwxr-xr-x | tests/du/two-args | 2 |
12 files changed, 23 insertions, 23 deletions
diff --git a/tests/du/2g b/tests/du/2g index 88cf86742..a901ddbe9 100755 --- a/tests/du/2g +++ b/tests/du/2g @@ -21,15 +21,15 @@ . "${srcdir=.}/init.sh"; path_prepend_ ../src print_ver_ du -# Creating a 2GB file counts as `very expensive'. +# Creating a 2GB file counts as 'very expensive'. very_expensive_ # Get number of free kilobytes on current partition, so we can # skip this test if there is insufficient free space. -# This technique relies on the fact that the `Available' kilobyte -# count is the number just before the one with a trailing `%'. +# This technique relies on the fact that the 'Available' kilobyte +# count is the number just before the one with a trailing '%'. free_kb=`df -kP .|tail -1|sed 's/ [0-9][0-9]*%.*//;s/ *$//;s/.* //'` case "$free_kb" in [0-9]*) ;; diff --git a/tests/du/8gb b/tests/du/8gb index 3926a36ee..e8803783c 100755 --- a/tests/du/8gb +++ b/tests/du/8gb @@ -29,7 +29,7 @@ fi # FIXME: this should be a test of dd. # On some systems (at least linux-2.4.18 + NFS to disks on a Solaris system) -# the `dd' command above mistakenly creates a file of length `0', yet +# the 'dd' command above mistakenly creates a file of length '0', yet # doesn't fail. The root of that failure is that the ftruncate call # returns zero but doesn't do its job. Detect this failure. set x `ls -gG big` @@ -41,7 +41,7 @@ Consider rerunning this test on a different file system." fi -# This would print `0 big' with coreutils-4.5.8. +# This would print '0 big' with coreutils-4.5.8. du -ab big > out || fail=1 cat <<\EOF > exp diff --git a/tests/du/deref b/tests/du/deref index 3de6aa4a9..cfd84563b 100755 --- a/tests/du/deref +++ b/tests/du/deref @@ -30,7 +30,7 @@ ln -s nowhere dangle || framework_failure_ # This used to fail with the following diagnostic: -# du: `b': No such file or directory +# du: 'b': No such file or directory du -sD slink b > /dev/null 2>&1 || fail=1 # This used to fail to report the dangling symlink. diff --git a/tests/du/files0-from b/tests/du/files0-from index fb25c3f0f..c62c2a805 100755 --- a/tests/du/files0-from +++ b/tests/du/files0-from @@ -43,7 +43,7 @@ my @Tests = # input file name of '-' ['minus-in-stdin', '--files0-from=-', '<', {IN=>{f=>'-'}}, {EXIT=>1}, {ERR => "$prog: when reading file names from stdin, no file name of" - . " `-' allowed\n"}], + . " '-' allowed\n"}], # empty input, regular file ['empty', '--files0-from=@AUX@', {AUX=>''}], diff --git a/tests/du/inacc-dest b/tests/du/inacc-dest index 61e01d8a2..c9c709759 100755 --- a/tests/du/inacc-dest +++ b/tests/du/inacc-dest @@ -40,13 +40,13 @@ cat <<\EOF > exp || fail=1 ./c ./d ./e -du: cannot read directory `./c': Permission denied +du: cannot read directory './c': Permission denied EOF # Map a diagnostic like this -# du: cannot access `./c/j': Permission denied +# du: cannot access './c/j': Permission denied # to this: -# du: cannot access `./c': Permission denied +# du: cannot access './c': Permission denied # And accept "cannot read directory" in place of "cannot access" sed "s,/c/j': ,/c': ," out > t && mv t out sed 's,cannot access,cannot read directory,' out > t && mv t out diff --git a/tests/du/long-from-unreadable b/tests/du/long-from-unreadable index c661bc1c3..10864e00e 100755 --- a/tests/du/long-from-unreadable +++ b/tests/du/long-from-unreadable @@ -18,10 +18,10 @@ # Show that fts (hence du, chmod, chgrp, chown) fails when all of the # following are true: -# - `.' is not readable +# - '.' is not readable # - operating on a hierarchy containing a relative name longer than PATH_MAX # - run on a system where gnulib's openat emulation must resort to using -# save_cwd and restore_cwd (which fail if `.' is not readable). +# save_cwd and restore_cwd (which fail if '.' is not readable). # Thus, the following du invocation should succeed on newer Linux and # Solaris systems, yet it must fail on systems lacking both openat and # /proc support. However, before coreutils-6.0 this test would fail even diff --git a/tests/du/long-sloop b/tests/du/long-sloop index b5b11f256..78926d38f 100755 --- a/tests/du/long-sloop +++ b/tests/du/long-sloop @@ -47,9 +47,9 @@ echo foo > $i # If a system can handle this many symlinks in a file name, # just skip this test. -# The following also serves to record in `err' the string +# The following also serves to record in 'err' the string # corresponding to strerror (ELOOP). This is necessary because while -# Linux/libc gives `Too many levels of symbolic links', Solaris +# Linux/libc gives 'Too many levels of symbolic links', Solaris # renders it as `Number of symbolic links encountered during path # name traversal exceeds MAXSYMLINKS'. @@ -61,7 +61,7 @@ too_many=`sed 's/.*: //' err` # With coreutils-5.93 there was no failure. # With coreutils-5.94 we get the desired diagnostic: -# du: cannot access `1/s/s/s/.../s': Too many levels of symbolic links +# du: cannot access '1/s/s/s/.../s': Too many levels of symbolic links du -L 1 > /dev/null 2> out1 && fail=1 sed "s, .1/s/s/s/[/s]*',," out1 > out || fail=1 diff --git a/tests/du/no-x b/tests/du/no-x index 9ba70770d..53084e1ca 100755 --- a/tests/du/no-x +++ b/tests/du/no-x @@ -32,9 +32,9 @@ prog=du # NOTE: this code is the same for all tests/*/no-x tests. # Depending on whether fts is using native fdopendir, we see one # of the following diagnostics (note also the /y suffix in one case): -# prog: `d/no-x': Permission denied -# prog: cannot access `d/no-x/y': Permission denied -# prog: cannot read directory `d/no-x': Permission denied +# prog: 'd/no-x': Permission denied +# prog: cannot access 'd/no-x/y': Permission denied +# prog: cannot read directory 'd/no-x': Permission denied # Convert either of the latter two to the first one. sed "s/^$prog: cannot access /$prog: /" out > t && mv t out sed "s/^$prog: cannot read directory /$prog: /" out > t && mv t out diff --git a/tests/du/restore-wd b/tests/du/restore-wd index 03d87e858..eb9dc98ef 100755 --- a/tests/du/restore-wd +++ b/tests/du/restore-wd @@ -24,7 +24,7 @@ mkdir a b || framework_failure_ # With du from coreutils-4.5.5 and 4.5.6, this would fail with -# du: `b': No such file or directory +# du: 'b': No such file or directory du a b > out || fail=1 diff --git a/tests/du/slash b/tests/du/slash index 0dfc1096f..24fc20079 100755 --- a/tests/du/slash +++ b/tests/du/slash @@ -1,5 +1,5 @@ #!/bin/sh -# `du /' would omit the `/' on the last line. +# 'du /' would omit the '/' on the last line. # Copyright (C) 2003-2004, 2006-2012 Free Software Foundation, Inc. diff --git a/tests/du/slink b/tests/du/slink index 99677f96c..1f8429171 100755 --- a/tests/du/slink +++ b/tests/du/slink @@ -19,14 +19,14 @@ . "${srcdir=.}/init.sh"; path_prepend_ ../src print_ver_ du -# Determine if `.' is on a local (would non-NFS be sufficient?) file system. +# Determine if '.' is on a local (would non-NFS be sufficient?) file system. # At least on OSF/1 4.0d, when using an nfsv3 file system, # each created symlink can end up having a size of 0. require_local_dir_ if df --type=xfs . >/dev/null 2>&1; then # At least on Irix-6.5.19, when using an xfs file system, - # each created symlink (name lengths up to 255) would have a size of `0'. + # each created symlink (name lengths up to 255) would have a size of '0'. skip_ "'.' is on an XFS file system" fi diff --git a/tests/du/two-args b/tests/du/two-args index 88d01339d..0d88c98ed 100755 --- a/tests/du/two-args +++ b/tests/du/two-args @@ -1,5 +1,5 @@ #!/bin/sh -# Make sure `du d/1 d/2' works. +# Make sure 'du d/1 d/2' works. # That command failed with du from fileutils-4.0q. # Copyright (C) 2000, 2004-2012 Free Software Foundation, Inc. |