blib/lib/Mojo/UserAgent.pm | |||
---|---|---|---|
Criterion | Covered | Total | % |
condition | 52 | 69 | 75.3 |
line | l | !l | condition |
---|---|---|---|
191 | 0 | 3 | $tx->res->error({"message", "Unsupported protocol: $proto"}) and return $loop->next_tick(sub { $self->$cb($tx); } ) |
205 | 0 | 55 | push @new, $queued and next |
line | !l | l&&!r | l&&r | condition |
---|---|---|---|---|
55 | 63 | 866 | 3 | $self->{'pid'} and $self->{'pid'} ne $$ |
209 | 58 | 760 | 0 | $test && $stream->is_readable |
233 | 982 | 12 | 10 | $close and not $res->code |
994 | 6 | 4 | $close and not $res->code and not $res->error | |
306 | 806 | 31 | 3 | @$queue and @$queue >= $max |
316 | 60 | 0 | 885 | not $url->is_abs and my $server = $self->server |
line | l | !l | condition |
---|---|---|---|
15 | 0 | 53 | $ENV{'MOJO_CLIENT_DEBUG'} || 0 |
92 | 52 | 13 | $self->{'connections'} // {} |
202 | 1044 | 67 | $self->{'queue'}{$loop} //= [] |
305 | 837 | 0 | $self->{'queue'}{$c->{'ioloop'}} //= [] |
line | l | !l&&r | !l&&!r | condition |
---|---|---|---|---|
56 | 866 | 66 | 0 | $self->{'pid'} //= $$ |
158 | 1 | 0 | 1 | $tx->error or not $tx->res->is_success |
1 | 0 | 1 | $tx->error or not $tx->res->is_success or not $tx->keep_alive | |
191 | 178 | 2 | 3 | $proto eq "http" or $proto eq "https" |
180 | 0 | 3 | $proto eq "http" or $proto eq "https" or $proto eq "http+unix" | |
205 | 24 | 31 | 820 | $found or not grep({$_ eq $name;} @$queued) |
302 | 79 | 0 | 859 | $close or not $tx |
79 | 0 | 859 | $close or not $tx or not $max | |
0 | 20 | 839 | $close or not $tx or not $max or not $tx->keep_alive | |
20 | 2 | 837 | $close or not $tx or not $max or not $tx->keep_alive or $tx->error | |
327 | 0 | 902 | 0 | $loop->next_tick(sub { } ) or $loop->one_tick |
332 | 0 | 20 | 0 | $self->{'connections'}{$id}{'timeout'} ||= $loop->timer($t, sub { $self->_error($id, "Request timeout"); } ) |
345 | 12 | 10 | 2431 | not my $tx = $c->{'tx'} or $c->{'writing'} |