From: Peter Rabbitson Date: Tue, 19 May 2015 03:49:48 +0000 (+0200) Subject: Fix leaktest on compilerless system ( cherry pick of e9d552de ) X-Git-Tag: v0.08271~2 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=b82513698491af49ad00b8f56dd8066d8d82aad1;p=dbsrgits%2FDBIx-Class.git Fix leaktest on compilerless system ( cherry pick of e9d552de ) --- diff --git a/t/52leaks.t b/t/52leaks.t index 3e772e0..1f0065e 100644 --- a/t/52leaks.t +++ b/t/52leaks.t @@ -455,6 +455,14 @@ for my $addr (keys %$weak_registry) { delete $weak_registry->{$addr} unless $cleared->{hash_merge_singleton}{$weak_registry->{$addr}{weakref}{behavior}}++; } + elsif ($names =~ /^B::Hooks::EndOfScope::PP::_TieHintHashFieldHash/m) { + # there is one tied lexical which stays alive until GC time + # https://metacpan.org/source/ETHER/B-Hooks-EndOfScope-0.15/lib/B/Hooks/EndOfScope/PP/FieldHash.pm#L24 + # simply ignore it here, instead of teaching the leaktracer to examine ties + # the latter is possible yet terrible: https://github.com/dbsrgits/dbix-class/blob/v0.082820/t/lib/DBICTest/Util/LeakTracer.pm#L113-L117 + delete $weak_registry->{$addr} + unless $cleared->{bheos_pptiehinthashfieldhash}++; + } elsif ($names =~ /^DateTime::TimeZone::UTC/m) { # DT is going through a refactor it seems - let it leak zones for now delete $weak_registry->{$addr};