Branch Coverage

blib/lib/Test/Moose/More.pm
Criterion Covered Total %
branch 131 150 87.3


line true false branch
92 202 380 if $THING_NAME
97 0 6 ref $thing ? :
0 6 &blessed($thing) ? :
374 6 !!$thing_meta ? :
121 31 50 unless ref $roles
131 41 0 if $^V gt v5.21.1
144 16 50 unless ref $roles
149 41 0 if $^V gt v5.21.1
164 54 67 $meta->isa('Moose::Meta::Role') ? :
233 4 21 unless my $mmeta = $meta->find_method_by_name($method)
317 4 51 if not $meta
328 40 11 if $type eq 'Class'
413 166 25 unless $args{-'subtest'}
415 3 22 if "$args{-'subtest'}" eq '1'
432 1 3 $args{'anonymous'} ? :
4 49 if exists $args{'anonymous'}
436 2 2 $args{'sugar'} ? :
4 49 if exists $args{'sugar'}
439 47 6 unless $args{'metaclasses'}
452 21 32 if (exists $args{'does'})
454 7 46 if (exists $args{'does_not'})
458 12 41 if (exists $args{'methods'})
460 4 49 if (exists $args{'no_methods'})
467 0 12 unless &has_attribute_ok($thing, $name)
470 4 8 unless (not $opts)
473 2 2 if find_meta($thing)->isa('Moose::Meta::Role')
492 1 36 unless &is_class_ok($class)
498 19 17 if (exists $args{'isa'})
502 0 2 if (exists $args{'immutable'} and $args{'immutable'})
504 2 34 if (exists $args{'immutable'} and not $args{'immutable'})
508 2 34 if (exists $args{'class_metaroles'})
510 2 34 if (exists $args{'no_class_metaroles'})
513 0 2 if $args{'class_metaclasses'} and $args{'metaclasses'}
516 2 34 if exists $args{'class_metaclasses'}
531 1 9 unless &is_role_ok($role)
534 2 7 if defined $args{'required_methods'}
537 1 8 if defined $args{'before'}
539 1 8 if defined $args{'around'}
541 1 8 if defined $args{'after'}
545 2 7 if (exists $args{'role_metaroles'})
547 2 7 if (exists $args{'no_role_metaroles'})
551 0 2 if $args{'role_metaclasses'} and $args{'metaclasses'}
554 2 7 if exists $args{'role_metaclasses'}
558 1 8 $args{-'compose'} ? :
565 0 1 unless $args{'required_methods'}
571 0 1 unless $args{'required_methods'}
572 0 0 unless $args{'required_methods'}
1 0 defined $args{'methods'} ? :
576 0 1 unless $args{'does'}
595 1 40 unless &has_attribute_ok($thing, $name)
614 4 38 if $thing_opts{'does'}
620 42 0 unless not $THING_NAME
622 4 38 if keys %thing_opts
633 0 8 unless &has_attribute_ok($thing, $name)
642 22 28 if $att->isa('Moose::Meta::Role::Attribute')
655 2 4 delete $opts{'required'} ? :
6 16 if exists $opts{'required'}
660 2 4 delete $opts{'lazy'} ? :
6 16 if exists $opts{'lazy'}
665 2 4 delete $opts{'coerce'} ? :
6 16 if exists $opts{'coerce'}
670 4 18 if keys %opts
687 5 23 if (my $is = delete $opts{'is'})
688 0 5 if $is eq 'rw' and not exists $opts{'accessor'}
689 5 0 if $is eq 'ro' and not exists $opts{'reader'}
702 21 4 defined $value ? :
710 4 4 delete $opts{'required'} ? :
8 20 if exists $opts{'required'}
719 4 24 if (exists $opts{'init_arg'})
722 4 0 $opts{'init_arg'} ? :
729 7 4 delete $opts{'lazy'} ? :
11 17 if exists $opts{'lazy'}
734 2 4 delete $opts{'coerce'} ? :
6 22 if exists $opts{'coerce'}
740 2 3 unless ($att->meta->find_attribute_by_name($opt))