Crypt-OpenSSL-CA

 view release on metacpan or  search on metacpan

t/lib/Crypt/OpenSSL/CA/Test.pm  view on Meta::CPAN


The minimum number of leaked bytes to look for.  The default is 65536.
Setting this too low will trigger false positives, as Perl does some
funky memory management eg in hash tables and that may cause jitter in
the memory consumption as measured from malloc's point of view.

=back

=cut

sub _total_heap_size() {
    require Devel::Mallinfo;
    my $mallinfo = Devel::Mallinfo::mallinfo();
    # From the perldoc of Devel::Mallinfo:
    return $mallinfo->{uordblks}+$mallinfo->{usmblks}+$mallinfo->{hblkhd};
}

sub leaks_bytes_ok (&@) {
    my ($coderef, %args) = @_;
    my $testname = $args{-name} || "leaks_bytes_ok";



( run in 0.266 second using v1.01-cache-2.11-cpan-1f129e94a17 )