summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorJim Meyering <meyering@redhat.com>2012-08-16 08:59:27 +0200
committerJim Meyering <meyering@redhat.com>2012-08-16 20:14:03 +0200
commit0c98bfa3596c4a9f87b3c07976c47246a8ad8684 (patch)
treeb5d0ad018f5c50bfafcfcd4370020b08dd31e9ba /tests
parent1e987a9966122e08a0d47cfd75baf63302314ea8 (diff)
downloadcoreutils-0c98bfa3596c4a9f87b3c07976c47246a8ad8684.tar.xz
tests: reverse args in Coreutils.pm-invoked diff, for consistency
* tests/Coreutils.pm (_compare_files): Reverse diff arguments so that we invoke diff -c $expected $actual, which is consistent with how init.sh-using tests invoke "compare exp out".
Diffstat (limited to 'tests')
-rw-r--r--tests/Coreutils.pm6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/Coreutils.pm b/tests/Coreutils.pm
index 0c8bb82c4..a0c1bba7d 100644
--- a/tests/Coreutils.pm
+++ b/tests/Coreutils.pm
@@ -130,14 +130,14 @@ sub _compare_files ($$$$$)
{
my ($program_name, $test_name, $in_or_out, $actual, $expected) = @_;
- my $differ = compare ($expected, $actual);
+ my $differ = compare ($actual, $expected);
if ($differ)
{
my $info = (defined $in_or_out ? "std$in_or_out " : '');
warn "$program_name: test $test_name: ${info}mismatch, comparing "
- . "$actual (actual) and $expected (expected)\n";
+ . "$expected (expected) and $actual (actual)\n";
# Ignore any failure, discard stderr.
- system "diff -c $actual $expected 2>/dev/null";
+ system "diff -c $expected $actual 2>/dev/null";
}
return $differ;