tests: use "compare exp out", not "compare out exp"
authorJim Meyering <meyering@redhat.com>
Tue, 29 Nov 2011 17:14:02 +0000 (18:14 +0100)
committerJim Meyering <meyering@redhat.com>
Tue, 29 Nov 2011 17:14:02 +0000 (18:14 +0100)
commitd3cd190bdbd88c83fd1487c43d268a5fb1df76a2
treed0798432dcf8ad153ef4130c3b2557f6ff817700
parentbe5391f32a3ca8795f29e0217cb04d9428e1129e
tests: use "compare exp out", not "compare out exp"

Likewise, when an empty file is expected, use "compare /dev/null out",
not "compare out /dev/null". I.e., specify the expected/desired contents
via the first file name.  Prompted by a suggestion from Bruno Haible
in http://thread.gmane.org/gmane.comp.gnu.grep.bugs/4020/focus=29154

Run these commands:

    git grep -l -E 'compare [^ ]+ exp' \
      |xargs perl -pi -e 's/\b(compare) (\S+) (exp\S*)/$1 $3 $2/'
    git grep -l -E 'compare [^ ]+ /dev/null' \
      |xargs perl -pi -e 's,\b(compare) (\S+) (/dev/null),$1 $3 $2,'
tests/helin-segv
tests/mixed
tests/null-suffix-clobber
tests/trailing-nul
tests/zdiff