Branch Coverage

blib/lib/Math/Random/MT/Auto.pm
Criterion Covered Total %
branch 58 96 60.4


line true false branch
72 26 12 if (exists $EXPORT_OK{lc $sym}) { }
7 5 elsif ($sym =~ /^:(no|!)?auto$/i) { }
86 0 5 if (@_ and &Scalar::Util::looks_like_number($_[0]))
93 14 5 unless (@sources)
94 0 14 if (exists $DISPATCH{'win32'}) { }
14 0 elsif (-e '/dev/urandom') { }
0 0 elsif (-e '/dev/random') { }
105 12 7 $auto_seed ? :
122 0 1 &Scalar::Util::blessed($_[0]) ? :
124 1 0 if (@_)
126 0 1 if (&Scalar::Util::looks_like_number($_[0]) or ref $_[0] eq 'ARRAY')
147 1 1 &Scalar::Util::blessed($_[0]) ? :
149 1 1 if (wantarray)
160 1 1 &Scalar::Util::blessed($_[0]) ? :
163 0 2 unless (@_)
168 2 0 if (ref $_[0] eq 'ARRAY') { }
183 3 4 &Scalar::Util::blessed($_[0]) ? :
185 7 0 if (wantarray)
196 4 2 &Scalar::Util::blessed($_[0]) ? :
199 6 0 if (ref $_[0] eq 'ARRAY') { }
254 10 20 unless (exists $sources_for{$$self})
260 1 29 if (exists $args->{'STATE'}) { }
265 18 11 unless (@{$seed_for{$$self};})
397 0 19 if ($ii + 1 < @{$sources;} and &Scalar::Util::looks_like_number($$sources[$ii + 1]))
400 0 0 if ($$sources[++$ii] < $need)
405 1 18 if (ref $src eq 'CODE') { }
3 15 elsif (defined $DISPATCH{$src_key}) { }
15 0 elsif (-e $src) { }
423 4 15 if (not @{$seed;}) { }
2 13 elsif (@{$seed;} < $FULL_SEED) { }
444 0 15 unless (open $FH, '<', $device)
451 15 0 if ($^O ne 'MSWin32' and $^O ne 'Haiku')
456 0 15 unless $flags = fcntl($FH, &Fcntl::F_GETFL, 0)
458 0 15 unless fcntl $FH, &Fcntl::F_SETFL, $flags | &Fcntl::O_NONBLOCK
461 0 15 if ($@)
471 4368 312 if (defined $cnt) { }
473 308 4060 if ($cnt < $INT_SIZE)
477 4060 308 if ($cnt = int $cnt / $INT_SIZE)
499 3 0 unless ($LWP_UA)
504 3 0 if ($@)
526 0 0 if ($content =~ /exceeded your 24-hour quota/) { }
582 0 0 if ($bytes > $www{$src}{'max_bytes'})
596 0 0 if ($@) { }
0 0 elsif ($res->is_success) { }
621 0 0 unless (defined $func)
627 0 0 unless ($func->Call($buffer, $bytes))
634 0 0 if ($@)
647 0 32 if ($Config::Config{'useithreads'} and $threads::shared::threads_shared and threads::shared::_id($seed)) { }