Branch Coverage

blib/lib/With/Roles.pm
Criterion Covered Total %
branch 32 44 72.7


line true false branch
18 2 15 if exists $COMPOSITE_NAME{$key}
36 0 15 if ($COMPOSITE_KEY{$new_name} or length $new_name > 252)
56 11 0 defined $type ? :
67 0 11 unless eval $code
69 0 11 if defined $e
88 9 0 if defined &mro::set_mro
95 1 10 if ($INC{'Moo/Role.pm'} and 'Moo::Role'->is_role($base)) { }
3 7 elsif ($INC{'Moo.pm'} and 'Moo'->_accessor_maker_for($base)) { }
0 7 elsif ($INC{'Class/MOP.pm'} and $meta = Class::MOP::class_of($base) and $meta->isa('Moose::Meta::Role')) { }
0 7 elsif ($INC{'Class/MOP.pm'} and $meta = Class::MOP::class_of($base) and $meta->isa('Class::MOP::Class')) { }
0 7 elsif (defined &Mouse::Util::find_meta and $meta = Mouse::Util::find_meta($base) and $meta->isa('Mouse::Meta::Role')) { }
0 7 elsif (defined &Mouse::Util::find_meta and $meta = Mouse::Util::find_meta($base) and $meta->isa('Mouse::Meta::Class')) { }
1 6 elsif ($INC{'Role/Tiny.pm'} and 'Role::Tiny'->is_role($base)) { }
145 6 0 if ($INC{'Role/Tiny.pm'} and not grep((!'Role::Tiny'->is_role($_)), @roles)) { }
160 0 13 unless @roles
165 12 1 unless $BASE{$base}
167 1 12 $self->can('ROLE_BASE') ? :
175 11 2 unless (exists $BASE{$new})
176 0 11 unless my $type = _detect_type($base, @roles)
181 6 5 if ($type eq 'Role::Tiny::With') { }
2 3 elsif ($type =~ /Role/) { }
199 2 11 if (ref $self)