Branch Coverage

lib/Pony/Object.pm
Criterion Covered Total %
branch 103 118 87.2


line true false branch
51 1 52 if defined *{$call . '::ALL';}
59 53 2 if ($call =~ /^$prefix/)
68 0 2 if keys %{$$default{''};} == keys %{$$default{$call};}
82 52 0 if $] >= 5.02
84 51 1 unless ($profile->{'noObject'})
106 2 50 if ($call->META->{'isAbstract'}) { }
113 1 49 if defined ${$call . '::instance';}
119 7 126 if (grep {$_ eq 'static';} @{$$p{'access'};})
127 1 48 if $call->META->{'isSingleton'}
130 3 46 if $call->can('init')
150 1 40 if ($param =~ /^-?singleton$/) { }
5 35 elsif ($param =~ /^-?abstract$/) { }
3 32 elsif ($param =~ /^:exceptions?$/ or $param =~ /^:try$/) { }
2 30 elsif ($param =~ /^:noexceptions?$/ or $param =~ /^:notry$/) { }
1 29 elsif ($param =~ /^:noobject$/) { }
207 1 30 if $call eq $base
209 30 0 if $base->can('AFTER_LOAD_CHECK')
224 51 1 unless ($profile->{'noObject'})
265 45 12 if ($attr eq 'Public') { }
3 9 elsif ($attr eq 'Protected') { }
3 6 elsif ($attr eq 'Private') { }
6 0 elsif ($attr eq 'Abstract') { }
280 6 46 if ($profile->{'withExceptions'})
287 12 10 if (defined wantarray) { }
288 8 4 if (wantarray == 0) { }
4 0 elsif (wantarray == 1) { }
290 6 2 if $@ and defined $catch
291 1 7 if defined $finally
296 2 2 if $@ and defined $catch
297 1 3 if defined $finally
303 8 2 if $@ and defined $catch
304 3 6 if defined $finally
333 30 0 if ($base->can('META'))
338 44 7 unless exists $this->META->{'methods'}{$k}
342 7 23 if ($base->META->{'isAbstract'})
359 38 42 if $this->META->{'checked'}
364 7 22 if ($base->can('META') and $base->META->{'isAbstract'})
374 11 0 if grep {$_ eq 'Abstract';} @{$base->META->{'methods'}{$method}{'attributes'};}
381 0 7 if (@bad)
403 9 8 if (ref $value ne 'CODE') { }
404 0 9 if ($attr =~ /^__/) { }
0 9 elsif ($attr =~ /^_/) { }
419 2 6 if ($attr =~ /^__/) { }
1 5 elsif ($attr =~ /^_/) { }
473 6 63 if exists $call->META->{'properties'}{$name} and $call->META->{'properties'}{$name}{'package'} ne $call
478 67 0 unless exists $props->{$name} or $props->{$name}{'package'} and $props->{$name}{'package'} ne $call
523 2 279 unless $call->isa($pkg) || $pkg->isa($call) and $this->isa($pkg)
550 1 6 unless $pkg->isa($call) and $this->isa($pkg)
575 4 15 unless $call->isa($pkg) || $pkg->isa($call) and $this->isa($pkg)
599 3 6 unless $pkg->isa($call) and $this->isa($pkg)
635 0 6 unless $pkg->META->{'isAbstract'}
664 6 36 if exists $classes{$c}
671 36 0 if ($base->can('ALL'))
675 56 21 unless (exists do { $this . '::ALL' }->{$k})
682 56 21 unless (exists $this->META->{'properties'}{$k})
704 0 65 if $$symcache{join $;, $pkg, $ref}
709 0 649 unless ref \$sym eq 'GLOB'
712 65 584 if *{$sym;}{$type} and *{$sym;}{$type} == $ref
737 3 4 unless exists $storage->{$name}