diff options
author | Per Øyvind Karlsen <peroyvind@mandriva.org> | 2010-10-04 23:02:39 +0000 |
---|---|---|
committer | Per Øyvind Karlsen <peroyvind@mandriva.org> | 2010-10-04 23:02:39 +0000 |
commit | 921cb3f57e90dea930cb17f910b2a9f61af83e8e (patch) | |
tree | 2e323fd2bd94b02fb02b108d4bd7cf5162b53823 | |
parent | d1ee01105ef052c30db476a989ef840e529a6c6d (diff) | |
download | perl-URPM-921cb3f57e90dea930cb17f910b2a9f61af83e8e.tar perl-URPM-921cb3f57e90dea930cb17f910b2a9f61af83e8e.tar.gz perl-URPM-921cb3f57e90dea930cb17f910b2a9f61af83e8e.tar.bz2 perl-URPM-921cb3f57e90dea930cb17f910b2a9f61af83e8e.tar.xz perl-URPM-921cb3f57e90dea930cb17f910b2a9f61af83e8e.zip |
check output of 'diff' in stead for better output
-rw-r--r-- | t/resolve.t | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/t/resolve.t b/t/resolve.t index 46ae32a..7891267 100644 --- a/t/resolve.t +++ b/t/resolve.t @@ -41,18 +41,14 @@ sub solve_check { open FILE, ">$file"; print FILE $out; - close FILE; - } else { - open (FILE, $file); - while (<FILE>) { - $in .= $_; - } close FILE; + } else { + open(my $diff, "|echo -n '$out' | diff -pu $file -") or die $!; + is(<$diff>, undef, "$file comparision"); + close($diff); } is(int @pkgs, $pkgtotal, "$pkg total number of packages"); - is($in, $out, "$file comparision"); - } SKIP: { |