Condition Coverage

blib/lib/Stash/REST.pm
Criterion Covered Total %
condition 43 78 55.1


and 3 conditions

line !l l&&!r l&&r condition
67 17 1 1 ref $uri ne '' and ref $uri ne 'ARRAY'
82 6 2 0 exists $conf{'headers'} and not grep({'Content-Type';} @{$conf{'headers'};})
10 8 0 ref $data ne 'ARRAY' and (exists $conf{'headers'} and not grep({'Content-Type';} @{$conf{'headers'};}))
85 1 0 0 exists $conf{'headers'} and grep {'Content-Type';} @{$conf{'headers'};}
17 1 0 exists $conf{'files'} and (exists $conf{'headers'} and grep {'Content-Type';} @{$conf{'headers'};})
89 9 5 4 not $can_have_body and $data
14 0 4 not $can_have_body and $data and ref $data eq 'ARRAY'
9 5 0 not $can_have_body and $data
168 14 3 0 exists $conf{'is_fail'} && $conf{'is_fail'}
202 0 0 1 $data && ref $data eq 'ARRAY'
206 17 0 0 exists $conf{'process_request'} and ref $conf{'process_request'} eq 'CODE'
217 17 0 0 exists $conf{'process_response'} and ref $conf{'process_response'} eq 'CODE'
223 15 1 1 $is_fail and $res->is_success
230 14 0 0 exists $conf{'process_response_success'} and ref $conf{'process_response_success'} eq 'CODE'
235 0 12 1 exists $conf{'method'} and $conf{'method'} eq 'HEAD'
241 12 0 0 exists $conf{'response_decoded'} and ref $conf{'response_decoded'} eq 'CODE'
251 0 4 0 ref $obj eq 'HASH' and exists $obj->{'id'}
255 0 4 0 $item_url and $conf{'automatic_load_item'}
261 3 0 0 exists $conf{'item_loaded'} and ref $conf{'item_loaded'} eq 'CODE'
270 3 0 0 exists $conf{'stash_added'} and ref $conf{'stash_added'} eq 'CODE'
275 1 10 0 $stashkey and exists $conf{'list'}
282 2 0 0 exists $conf{'list_loaded'} and ref $conf{'list_loaded'} eq 'CODE'
310 0 5 1 $prepare_request and ref $prepare_request ne 'CODE'
370 0 3 0 $prepare_request and ref $prepare_request ne 'CODE'

or 3 conditions

line l !l&&r !l&&!r condition
171 13 4 0 $code ||= $is_fail ? 400 : 201
224 1 0 15 $is_fail or $res->is_success