X-Git-Url: http://git.vpit.fr/?a=blobdiff_plain;f=gen.pl;h=828a6b9279380589ced71dade59828d527b155de;hb=8d66aa098b18f8c9724b12bf446d330905122c57;hp=ff82e873813d9f3d8cbcf11bae6a0288a414a587;hpb=4c46bbd0856ded38b0cefbabc61dc53b85025d42;p=perl%2Fmodules%2FTest-Valgrind.git diff --git a/gen.pl b/gen.pl index ff82e87..828a6b9 100755 --- a/gen.pl +++ b/gen.pl @@ -5,16 +5,24 @@ use warnings; use Test::More; eval <<'EOD'; -use Test::Valgrind diag => 1, - no_test => 1, - no_supp => 1, - extra => [ - q{--show-reachable=yes}, - q{--gen-suppressions=all}, -# q{--log-fd=1} - ] +use Test::Valgrind + diag => 1, + no_test => 1, + no_supp => 1, + callers => 50, + extra => [ qw/--show-reachable=yes --gen-suppressions=all/ ] EOD -plan skip_all => 'Test::Valgrind is required to run test your distribution with valgrind' if $@; +if ($@) { + plan skip_all => 'Test::Valgrind is required to run test your distribution with valgrind'; +} else { + eval { + require XSLoader; + XSLoader::load('Test::Valgrind', $Test::Valgrind::VERSION); + }; + unless ($@) { + Test::Valgrind::notleak("valgrind it!"); + } +} 1;