[libcode-tidyall-perl] 71/374: fix test
Jonas Smedegaard
js at alioth.debian.org
Sun Sep 29 22:25:51 UTC 2013
This is an automated email from the git hooks/post-receive script.
js pushed a commit to branch master
in repository libcode-tidyall-perl.
commit aebc6dbf841072405ad5ac39dfe4a411f1dccf87
Author: Jonathan Swartz <swartz at pobox.com>
Date: Tue Jul 3 15:10:34 2012 -0700
fix test
---
lib/Code/TidyAll/t/Basic.pm | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/lib/Code/TidyAll/t/Basic.pm b/lib/Code/TidyAll/t/Basic.pm
index aa347b7..2b3994e 100644
--- a/lib/Code/TidyAll/t/Basic.pm
+++ b/lib/Code/TidyAll/t/Basic.pm
@@ -37,14 +37,15 @@ sub tidy {
%$options
);
- my $result;
- my $output = capture_stdout { $result = $ct->process_all() };
+ my @results;
+ my $output = capture_stdout { @results = $ct->process_all() };
+ my $error_count = grep { $_->error } @results;
if ( $params{errors} ) {
like( $output, $params{errors}, "$desc - errors" );
- ok( $result->error_count > 0, "$desc - error_count > 0" );
+ ok( $error_count > 0, "$desc - error_count > 0" );
}
else {
- is( $result->error_count, 0, "$desc - error_count == 0" );
+ is( $error_count, 0, "$desc - error_count == 0" );
}
while ( my ( $path, $content ) = each( %{ $params{dest} } ) ) {
is( read_file("$root_dir/$path"), $content, "$desc - $path content" );
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libcode-tidyall-perl.git
More information about the Pkg-perl-cvs-commits
mailing list