Condition Coverage

blib/lib/Starlet/Server.pm
Criterion Covered Total %
condition 48 81 59.2


and 3 conditions

line !l l&&!r l&&r condition
57 112 0 0 $args{'max_workers'} and $args{'max_workers'} > 1
104 0 129 0 $^O eq 'linux' and $listen->{'_is_tcp'}
182 102 0 0 $may_keepalive and $max_reqs_per_child
102 0 0 $may_keepalive and $max_reqs_per_child and $proc_req_count >= $max_reqs_per_child
399 1 0 0 $$use_keepalive_r and lc $v ne 'keep-alive'
415 1 10 79 defined $protocol and $protocol eq 'HTTP/1.1'
427 0 0 0 not Plack::Util::status_with_no_entity_body($status_code) and defined(my $cl = Plack::Util::content_length($body))
444 2 5 83 defined $body and ref $body eq 'ARRAY'
7 1 82 defined $body and ref $body eq 'ARRAY' and @$body == 1
6 2 80 defined $body and ref $body eq 'ARRAY' and @$body == 1 and length $body->[0] < 8192
484 4 2 2 $use_chunked and not $completed
518 11 1 0 not defined $ret and $! == 4 || $! == 11 || $! == 11

or 2 conditions

line l !l condition
54 9 103 $args{'listens'} || []
70 42 $args{'host'} || 0
6 1 $args{'port'} || $args{'socket'} || 8080
0 112 $args{'timeout'} || 300
0 112 $args{'keepalive_timeout'} || 2
0 112 $args{'max_keepalive_reqs'} || 1
3 109 $args{'server_ready'} || sub { }
0 111 $args{'max_reqs_per_child'} || $args{'max_requests'} || 100
0 112 $args{'spawn_interval'} || 0
2 110 $args{'child_exit'} || sub { }
174 102 0 $listen->{'port'} || 0
83 19 $listen->{'host'} || 0

or 3 conditions

line l !l&&r !l&&!r condition
54 0 112 0 $args{'server_software'} || $class
111 0 3 0 $self->{'lock_path'} ||= do { my($fh, $lock_path) = tempfile('UNLINK', 1); close $fh; $lock_path }
137 0 268 0 not defined $max_reqs_per_child or $proc_req_count < $max_reqs_per_child
416 4 0 75 defined $send_headers{'content-length'} or defined $send_headers{'transfer-encoding'}
427 0 0 0 defined $send_headers{'content-length'} or defined $send_headers{'transfer-encoding'}
506 108 0 151 $is_write or delete $self->{'_is_deferred_accept'}
518 1 0 0 $! == 4 || $! == 11 || $! == 11