summaryrefslogtreecommitdiff
path: root/t/TEST
diff options
context:
space:
mode:
authorGeorge Greer <perl@greerga.m-l.org>2010-07-02 18:50:12 -0400
committerH.Merijn Brand <h.m.brand@xs4all.nl>2010-07-03 08:53:23 +0200
commite07ce2e4e82e3054dc912dbe99348744647bf30b (patch)
tree443ed0560cfd2d551fb3c751b77ea6f85d60a099 /t/TEST
parent9e2bec029fb0c747ff8d682f110159537237714b (diff)
downloadperl-e07ce2e4e82e3054dc912dbe99348744647bf30b.tar.gz
Adjust 'make test.valgrind' to account for cpan/dist/ext separation.
Signed-off-by: H.Merijn Brand <h.m.brand@xs4all.nl>
Diffstat (limited to 't/TEST')
-rwxr-xr-xt/TEST11
1 files changed, 8 insertions, 3 deletions
diff --git a/t/TEST b/t/TEST
index 205a8aabff..d4bf64c97c 100755
--- a/t/TEST
+++ b/t/TEST
@@ -91,7 +91,7 @@ if ($::do_nothing) {
}
# Location to put the Valgrind log.
-my $Valgrind_Log = 'current.valgrind';
+our $Valgrind_Log;
$| = 1;
@@ -296,13 +296,17 @@ sub _cmd {
my $redir = $^O eq 'VMS' ? '2>&1' : '';
if ($ENV{PERL_VALGRIND}) {
+ my $perl_supp = $options->{return_dir} ? "$options->{return_dir}/perl.supp" : "perl.supp";
my $valgrind = $ENV{VALGRIND} // 'valgrind';
my $vg_opts = $ENV{VG_OPTS}
- // "--suppressions=perl.supp --leak-check=yes "
+ // "--suppressions=$perl_supp --leak-check=yes "
. "--leak-resolution=high --show-reachable=yes "
- . "--num-callers=50";
+ . "--num-callers=50 --track-origins=yes";
$perl = "$valgrind --log-fd=3 $vg_opts $perl";
$redir = "3>$Valgrind_Log";
+ if ($options->{run_dir}) {
+ $Valgrind_Log = "$options->{run_dir}/$Valgrind_Log";
+ }
}
my $args = "$options->{testswitch} $options->{switch} $options->{utf8}";
@@ -549,6 +553,7 @@ EOT
$te = '';
}
+ (local $Valgrind_Log = "$test.valgrind-current") =~ s/^.*\///;
my $results = _run_test($test, $type);
my $failure;