Branch Coverage

blib/lib/Net/Async/Webservice/S3.pm
Criterion Covered Total %
branch 111 130 85.3


line true false branch
203 85 181 if exists $args{$_}
235 0 84 unless defined $args{'content'}
239 12 89 unless defined(my $value = $args{'query_params'}{$key})
247 84 0 $self->{'ssl'} // 1 ? :
250 84 0 if (length $bucket <= 63 and $bucket =~ /^[A-Z0-9][A-Z0-9.-]+$/i) { }
256 42 42 if @params
264 54 30 unless $args{'headers'}
285 51 33 if (defined $request->uri->query and length $request->uri->query)
289 49 53 if exists $params{$_}
294 49 0 defined $params{$_} ? :
297 29 22 if @params_to_sign
302 3 194 if $_[0] =~ /^X-Amz-/i
340 11 66 unless ($code =~ /^2/)
381 3 77 $prev_f ? :
388 64 14 unless my($failure, $name, $response, $request) = $f->failure
389 5 4 if defined $name and $name eq 'http' and $response and $response->code =~ /^4/
464 1 12 $prev_f ? :
490 1 3 if defined $self->{'prefix'}
503 2 2 if defined $self->{'prefix'}
509 1 7 if ($xpc->findvalue('.//s3:IsTruncated') eq 'true')
516 8 5 if not $f->failure
619 1 17 if defined $byte_range
622 3 18 if (my $pos = $value_len)
630 4 17 defined $if_match ? :
4 17 defined $byte_range ? :
644 7 14 if ($head_future->is_cancelled or not $code =~ /^2/)
649 7 7 if @_
656 2 15 if $_[0] =~ /^X-Amz-Meta-(.*)$/i
659 12 2 unless ($value_future)
671 0 25 if $code == 204
673 14 11 if (@_)
675 3 11 if ($on_chunk) { }
690 12 9 unless $resume_on_stall and $prev_f->failure
693 6 3 if $op ne 'stall_timeout'
699 1 11 if $head_future->is_cancelled
707 1 4 $stall_failure_f ? :
5 1 if not $f->is_cancelled
909 29 6 if (not defined $content && ref $content) { }
6 0 elsif (ref $content eq 'CODE') { }
0 0 elsif (&blessed($content) and $content->isa('Future')) { }
911 29 0 if (defined $content) { }
912 0 29 if length $content > $len
925 6 6 if $$posref >= $content_length
928 0 6 if $len > $read_size
961 4 23 ref $content ? :
2 27 @_ > 1 ? :
962 0 29 unless defined $content_length
977 7 22 $on_write ? :
983 0 27 unless defined(my $etag = $resp->header('ETag'))
989 0 27 unless my($got_md5) = lc($etag) =~ /^"([0-9a-f]{32})"$/
994 0 27 if ($got_md5 ne $expect_md5)
1098 6 14 $on_write ? :
1100 11 20 unless my(@content) = &$gen_parts()
1102 17 3 if @content == 1
1103 3 0 if @content == 2 and ref $content[0] eq 'CODE'
1107 0 0 ref $_ ? :
1142 9 9 if ($gen_parts = delete $args{'gen_parts'}) { }
1150 0 9 if ($content_length > $part_size * 10000) { }
1 8 elsif ($content_length > $part_size) { }
1155 1 2 unless length $args{'value'}
1161 8 8 unless @parts
1170 17 1 if @_
1174 9 9 if (@{$parts[1];}) { }
8 1 elsif (@{$parts[0];}) { }
1176 18 13 @parts ? :