[svn:parrot] r43906 - trunk/tools/dev
coke at svn.parrot.org
coke at svn.parrot.org
Thu Feb 11 14:35:41 UTC 2010
Author: coke
Date: Thu Feb 11 14:35:38 2010
New Revision: 43906
URL: https://trac.parrot.org/parrot/changeset/43906
Log:
Make the test diagnostics here usable.
(comparing very long strings that only differ by a bit is hard.)
Modified:
trunk/tools/dev/checkdepend.pl
Modified: trunk/tools/dev/checkdepend.pl
==============================================================================
--- trunk/tools/dev/checkdepend.pl Thu Feb 11 14:00:17 2010 (r43905)
+++ trunk/tools/dev/checkdepend.pl Thu Feb 11 14:35:38 2010 (r43906)
@@ -11,6 +11,7 @@
use File::Spec;
use Test::More;
use Test::Harness;
+use Test::Differences;
=head1 NAME
@@ -29,8 +30,9 @@
=head1 REQUIREMENTS
A built parrot (Configure and make) to generate all files so we can analyze
-them. Ack is used to find the files. We are not currently requiring ack
-for development, so this is an optional test.
+them. App::Ack is used to find the files, and Test::Differences is used to
+make the test output usable - these non standard modules make this an
+optional test.
=head1 BUGS
@@ -262,10 +264,10 @@
$extra_info = "($active_makefile: line $active_line_num)";
}
- $rule_deps = join ' ', sort split /\s+/, $rule_deps;
- my $expected_deps = join ' ', sort (get_deps($file));
+ $rule_deps = join "\n", sort split /\s+/, $rule_deps;
+ my $expected_deps = join "\n", sort (get_deps($file));
- is($rule_deps, $expected_deps, "$file has correct dependencies $extra_info.");
+ eq_or_diff_text($rule_deps, $expected_deps, "$file has correct dependencies $extra_info.", {context => 0});
}
}
More information about the parrot-commits
mailing list