Permalink
Browse files

adding summary of all failed tests

  • Loading branch information...
1 parent 7bced5d commit 1107683d68bf10f377eb27f7ba796bb79893b3e5 @xsawyerx committed May 29, 2010
Showing with 11 additions and 2 deletions.
  1. +11 −2 test.pl
View
13 test.pl
@@ -12,6 +12,7 @@
our $VERSION = '0.03';
my $droid = Android->new();
my $count = 0;
+my @failed = ();
sub event_loop {
for my $i ( 1 .. 10 ) {
@@ -208,12 +209,20 @@ sub event_loop {
);
foreach my $test (@tests) {
-
my ( $name, $callback ) = @{$test};
$count++;
- print $callback->() ? 'ok' : 'not ok';
+
+ if ( $callback->() ) {
+ print 'ok';
+ } else {
+ print 'not ok';
+ push @failed, $name;
+ }
+
print " $count - $name\n";
}
print "1..$count\n";
+print map { "# failed test '$_'\n" } @failed;
+

0 comments on commit 1107683

Please sign in to comment.