Condition Coverage

blib/lib/Search/Elasticsearch/Role/Cxn.pm
Criterion Covered Total %
condition 28 44 63.6


and 3 conditions

line !l l&&!r l&&r condition
97 166 1 3 $params->{'port'} and not $node =~ m(//[^/\[]+:\d+)
330 4 1 233 $mime_type && $mime_type ne 'text/plain'
342 0 62 176 $code >= 200 and $code <= 209
343 34 1 141 defined $body and length $body
360 49 0 0 defined $body and length $body
376 2 0 0 $error_type eq "Conflict" and $msg =~ /: version conflict, current (?:version )?\[(\d+)\]/

or 2 conditions

line l !l condition
90 175 0 $params->{'node'} || {'host', 'localhost', 'port', '9200'}
110 173 2 $node->{'host'} || 'localhost'
111 1 172 $node->{'userinfo'} || $params->{'userinfo'} || ''
118 1 165 $node->{'path'} || $params->{'path_prefix'} || ''
328 234 4 $headers->{'content-type'} || ''
409 2 0 $body->{'error'} || (return)
412 0 0 $error->{'root_cause'} || []

or 3 conditions

line l !l&&r !l&&!r condition
113 170 5 0 $node->{'scheme'} || ($params->{'use_https'} ? 'https' : 'http')
117 0 4 0 $node->{'port'} || $params->{'port'} || ($scheme eq 'http' ? 80 : 443)
374 2 0 0 $self->_munge_elasticsearch_exception($body) || $msg
380 60 0 0 $msg ||= $error_type