]> git.vpit.fr Git - perl/modules/Test-Valgrind.git/blobdiff - t/lib/Test/Valgrind/Test/Action.pm
Make sure t/20-bad.t does no extra checks when no valgrind was found
[perl/modules/Test-Valgrind.git] / t / lib / Test / Valgrind / Test / Action.pm
index c56eb038f553ee8c4d402009d6d734c7b575494d..3f9c0c7bea7632e3ae3cd07d01eb7c7fc7e2bd14 100644 (file)
@@ -18,12 +18,20 @@ BEGIN {
  } else {
   $extra_tests = 3;
   *report = *report_smart;
+  *abort  = *abort_smart;
  }
 }
 
 use Test::Builder;
 
-sub new { shift->SUPER::new(extra_tests => $extra_tests) }
+sub new {
+ my $class = shift;
+
+ $class->SUPER::new(
+  diag        => 1,
+  extra_tests => $extra_tests,
+ );
+}
 
 my @filtered_reports;
 
@@ -53,6 +61,14 @@ sub report_smart {
  $self->SUPER::report($sess, $report);
 }
 
+sub abort_smart {
+ my $self = shift;
+
+ $extra_tests = 0;
+
+ $self->SUPER::abort(@_);
+}
+
 sub DESTROY {
  return unless $extra_tests;