Branch Coverage

blib/lib/Mock/Data.pm
Criterion Covered Total %
branch 29 50 58.0


line true false branch
20 0 17 ref $class ? :
27 13 4 if (@_)
28 0 4 @_ == 1 && ref $_[0] eq 'HASH' ? :
9 4 @_ == 1 && ref $_[0] eq 'ARRAY' ? :
32 11 2 if (my $plugins = $args->{'plugins'})
33 11 0 ref $plugins ? :
36 3 10 if $args->{'generators'}
56 0 0 if ref($_)->can("clone")
63 209 0 if @_ == 1
73 0 35 if @_ > 1
81 0 14 if $self->{'_loaded_plugins'}{$name}
83 0 14 unless ($class->can("apply_mockdata_plugin"))
85 0 0 unless $class->can("apply_mockdata_plugin")
89 0 14 unless ref $self and ref($self)->isa("Mock::Data")
99 3 10 @_ == 1 ? :
105 72 10 if $name =~ /::([^:]+)$/
113 0 4 @_ == 1 ? :
118 0 4 if (defined(my $cur = $self->generators->{$name}))
125 4 0 if ($name =~ /::([^:]+)$/)
127 1 3 if (defined(my $cur = $self->generators->{$name}))
140 0 367 unless defined $self->{'generators'}{$name}
142 193 174 if @_
152 0 0 unless defined $gen
154 0 0 @_ ? :
161 0 357 unless ref $self