Branch Coverage

blib/lib/Flickr/Upload.pm
Criterion Covered Total %
branch 28 70 40.0


line true false branch
20 2 0 unless defined $t and exists $$t{'children'}
23 0 0 unless defined $n and exists $$n{'name'} and exists $$n{'children'}
24 0 0 unless $$n{'name'} eq $node
27 0 0 unless exists $$m{'name'} and $$m{'name'} eq $tag and exists $$m{'children'}
114 0 1 unless $self->isa('Flickr::Upload')
118 0 1 unless $args{'photo'} and -f $args{'photo'}
119 0 1 unless defined $args{'auth_token'}
123 0 1 unless defined $req
156 0 0 unless $self->isa('Flickr::API')
158 0 0 unless @_
160 0 0 @_ == 1 ? :
162 0 0 unless defined $res and $$res{'success'}
167 0 0 unless defined $$res{'tree'} and exists $$res{'tree'}{'children'}
169 0 0 unless defined $n and exists $$n{'name'} and $$n{'children'}
170 0 0 unless $$n{'name'} eq 'uploader'
173 0 0 unless exists $$m{'name'} and $$m{'name'} eq 'ticket' and exists $$m{'attributes'}
214 0 1 unless $self->isa('Flickr::Upload')
218 0 1 unless $args{'auth_token'}
238 1 0 if (defined $photo)
239 1 0 if ref $photo ne 'ARRAY'
267 0 1 unless $self->isa('LWP::UserAgent')
269 0 1 unless $req->isa('HTTP::Request')
279 0 3 unless defined $res
281 0 3 if ($res->is_success) { }
283 0 0 unless defined $tree
286 1 2 $try == $tries ? :
296 1 0 unless (defined $photoid or defined $ticketid)
301 0 0 defined $photoid ? :
347 9001 69437 unless ref $$s eq 'HASH'
351 15229 63209 if $$$s{'done'}
353 23471 39738 if (not $$$s{'in'}) { }
358 23471 0 defined $$chunk ? :
360 9001 14470 if ($$$s{'data'} =~ /Content-Type: .*?\r\n\r\n/g) { }
370 0 9001 if ($$$s{'size'} >= $img_size) { }
387 9001 30737 if ($$$s{'size'} + $size >= $img_size) { }