Condition Coverage

blib/lib/Perlbal/Service.pm
Criterion Covered Total %
condition 43 140 30.7


and 3 conditions

line !l l&&!r l&&r condition
750 0 0 0 $check_role and $check_role ne '*'
0 0 0 $check_role and $check_role ne '*' and $check_role ne $role
752 0 0 0 $check_type and $check_type eq 'size'
760 0 0 0 defined $default and $value eq $default
767 0 0 0 $check_type and $check_type eq 'bool'
868 953 40 0 ref $req_type eq 'ARRAY' and $$req_type[0] eq 'enum'
953 0 40 ref $req_type eq 'ARRAY' and $$req_type[0] eq 'regexp'
995 0 0 2 $name and $hashref
0 0 2 $name and $hashref and ref $hashref eq 'HASH'
1016 0 0 0 $role and $creator
0 0 0 $role and $creator and ref $creator eq 'CODE'
1100 0 0 0 $pclass and $key
0 0 0 $pclass and $key and $coderef
1108 0 0 0 $pclass and $key
1151 16 0 20 defined $$self{'pending_connects'}{$$be{'ipport'}} and defined $be
16 0 20 defined $$self{'pending_connects'}{$$be{'ipport'}} and defined $be and $$self{'pending_connects'}{$$be{'ipport'}} == $be
1199 139 0 0 $$self{'queue_relief_size'} > 0 and scalar @{$$self{'waiting_clients'};} >= $$self{'queue_relief_size'}
1208 0 139 0 $hp_first and $cp = shift @{$$self{'waiting_clients_highpri'};}
1312 0 0 0 defined $retry_time and $retry_time > 0
1335 0 0 135 $cp and not $$cp{'closed'}
1376 115 0 0 not $$be{'has_attention'} and $$be{'create_time'} < $now - 5
1383 115 0 0 $$be{'disconnect_at'} and $now + 2 > $$be{'disconnect_at'}
1474 0 0 0 $age >= 5 and $$be{'state'} eq 'connecting'
0 0 0 $age >= 60 and $$be{'state'} eq 'verifying_backend'
1522 0 0 2 defined $val and length $val
1560 74 15 0 not $res and $$self{'default_service'}
1637 0 3 39 not $listener and $$self{'listen'}
1676 0 0 0 $$self{'role'} eq 'management' and not $force
1787 2 0 4 $header and $value = $reshd->header($header)

or 2 conditions

line l !l condition
655 43 1 $name ||= ''
863 1017 61 $$self{'role'} || ''
1066 0 2 $$self{'hooks'}{$hook} ||= []
1345 0 0 $hd->header('Cookie') || ''
1349 0 0 $cookie{$cname} || ''
1696 0 0 $$self{'listen'} || '--'
1711 0 0 $$self{'_stat_cache_hits'} || 0
1712 0 0 eval { do { $hits / ($$self{'_stat_requests'} || 0) * 100 } } || 0
1720 0 0 eval { do { sprintf '%0.02f%%', $size / $maxsize * 100 } } || 'undef'
1734 0 0 $$self{'pool'}->node_used($hostport) || 0
1780 0 2 $reqhd->header('Host') || ''
1781 2 0 $reqhd->request_uri || ''
1800 3 3 $refs{$key} || ($refs{$key} = \$key)

or 3 conditions

line l !l&&r !l&&!r condition
803 731 361 1234 $$tun{'check_role'} eq '*' or $$tun{'check_role'} eq $$self{'role'}
829 226 858 0 $mc ||= 'Perlbal::ManageCommand'->loud_crasher
857 0 0 1084 $key eq 'nodefile' or $key eq 'balance_method'
863 408 670 0 ($$self{'role'} || '') eq $req_role or $req_role eq '*'
894 0 86 0 -f $val or $val eq $$tun{'default'}
896 43 0 0 not defined $val or -d $val
1358 0 0 135 $hi_pri or $low_pri
1522 2 0 0 defined $val and length $val or $mode eq 'remove'
1698 0 0 0 $$self{'role'} eq 'reverse_proxy' or $$self{'role'} eq 'web_server'