Condition Coverage

blib/lib/Clustericious/Client.pm
Criterion Covered Total %
condition 41 111 36.9


and 3 conditions

line !l l&&!r l&&r condition
149 0 1 0 $self->res->code and $self->res->is_success
169 0 0 0 $c->tx and $c->tx->error
170 0 0 0 $c->res and not $c->res->is_success
304 0 11 0 $meta and $meta->get('auto_failover')
306 0 0 11 $self->server_url and not $url =~ /^http/
313 7 4 0 $method eq 'POST' and grep /^--/, @args
341 0 7 4 $meta and my $arg_spec = $meta->get('args')
360 0 1 0 $method eq 'GET' and $arg =~ s/^--//
0 1 0 $method eq 'GET' and $arg =~ s/^-//
1 0 0 $method eq 'POST' and not ref $arg
362 0 1 0 $meta and $meta->get('skip_existing')
383 0 0 0 $args[0] and ref $args[0] eq 'HASH'
397 9 1 1 $body and ref $body eq 'HASH'
413 11 0 0 ($tx->res->code || 0) == 401 and $auth_header = $tx->res->headers->www_authenticate
11 0 0 ($tx->res->code || 0) == 401 and $auth_header = $tx->res->headers->www_authenticate and not $url->userinfo
0 0 0 ($tx->res->code || 0) == 401 and $auth_header = $tx->res->headers->www_authenticate and not $url->userinfo and $self->_has_auth || $self->_can_auth
443 1 0 0 $ENV{'ACPS_SUPPRESS_404'} and $url =~ /$ENV{'ACPS_SUPPRESS_404'}/
557 0 0 0 $config->username('default', '') && password('default', '')

or 2 conditions

line l !l condition
98 0 17 $ENV{'CLUSTERICIOUS_KEEP_ALIVE_TIMEOUT'} || 300
161 0 0 $error->{'message'} // ''
178 17 0 $VERSION // 'dev'
179 9 8 do { no strict 'refs'; ${"${class}::VERSION";} } // 'dev'
192 13 4 shift() || 'GET'
334 1 0 $body ||= {}
338 0 1 $body ||= {}
394 0 11 $headers->{'Connection'} ||= 'Close'
395 0 11 $headers->{'Accept'} ||= 'application/json'
413 7 4 $tx->res->code || 0
436 5 0 $msg ||= 'unknown error'
447 0 0 $res->body || ''

or 3 conditions

line l !l&&r !l&&!r condition
82 0 0 0 eval { do { $ua->server->app($app) } } // $ua->app($app)
168 0 0 3 $c->tx or $c->res
191 17 0 0 pop() || "/$subname"
252 0 1 0 shift() || "/$objname"
388 11 0 0 $url->is_abs or $self->{'app'}
397 1 0 10 $body and ref $body eq 'HASH' or ref $body eq 'ARRAY'
413 0 0 0 $self->_has_auth || $self->_can_auth
424 6 0 0 $res->headers->content_type || do { WARN('No content-type from ' . _sanitize_url($url)); 'text/plain' }
547 2 1 0 $self->{'_base_config'}{'url'} //= 'Clustericious'->_default_url($config_name)
574 0 0 0 $ENV{'USER'} // $ENV{'USERNAME'}
583 13 10 0 shift() || [caller 1]->[3]