Branch Coverage

blib/lib/SOAP/Transport/HTTP.pm
Criterion Covered Total %
branch 34 190 17.8


line true false branch
36 0 12 if $_patched
50 0 1 if (defined $_[2]->header('Connection') and $_[2]->header('Connection') eq 'Keep-Alive')
58 0 0 $_[2]->header('Content-Length') && SOAP::Utils::bytelength($$data) == $_[2]->header('Content-Length') ? :
61 0 0 $done++ ? :
74 12 11 if (@_)
80 11 154 if (@_)
94 0 12 if ref $class
96 12 0 unless (grep {$_ eq $SOAP::Transport::HTTP::Client::USERAGENT_CLASS;} @SOAP::Transport::HTTP::Client::ISA)
100 0 12 unless eval "require $SOAP::Transport::HTTP::Client::USERAGENT_CLASS"
106 12 0 if $SOAP::Constants::PATCH_HTTP_KEEPALIVE
110 12 0 $class->can($_[0]) ? :
116 0 12 unless $self->isa('LWP::UserAgent')
128 0 12 ref $params eq 'ARRAY' ? :
166 0 11 if ($parts)
189 0 11 if exists $redirect{$endpoint}
192 0 11 if exists $mpost{$endpoint}
209 0 11 if ($] < 5.008) { }
221 0 11 if $compressed
226 0 11 if $ENV{'HTTP_proxy_user'} and $ENV{'HTTP_proxy_pass'}
231 0 11 if ($method eq 'M-POST') { }
235 0 0 if defined $action
239 11 0 if defined $action
246 0 11 if $self->options->{'is_compress'}
250 0 11 if $compressed
254 11 0 if (not $http_request->content_type) { }
0 0 elsif (not $SOAP::Constants::DO_NOT_USE_CHARSET and $encoding) { }
255 10 1 !$SOAP::Constants::DO_NOT_USE_CHARSET && $encoding ? :
267 0 0 unless $tmpType =~ /$addition/
275 0 11 if $ENV{'HTTP_proxy'}
284 0 11 if ($self->http_response->code == 510 || $self->http_response->code == 501 and $method ne 'M-POST') { }
0 11 elsif ($self->http_response->code == 415 and $compressed) { }
306 0 11 if $self->http_response->previous and $self->http_response->previous->is_redirect
316 0 11 if $$self{'_cookie_jar'}
319 0 11 ($self->http_response->content_encoding || '') =~ /\S/ ? :
0 11 ($self->http_response->content_encoding || '') =~ /\b$SOAP::Transport::HTTP::Client::COMPRESS\b/o && $self->options->{'is_compress'} ? :
328 0 11 $self->http_response->content_type =~ m[^multipart/]i ? :
349 0 0 if ref $self
355 0 0 if $action and $action ne join('#', @_) and $action ne join('/', @_) and substr($_[0], -1, 1) ne '/' || $action ne join('', @_)
375 0 0 @_ ? :
386 0 0 if ($self->request->method eq 'POST') { }
0 0 elsif ($self->request->method eq 'M-POST') { }
390 0 0 unless $self->request->header('Man') =~ /^"$SOAP::Constants::NS_ENV";\s*ns\s*=\s*(\d+)/
411 0 0 if $compressed and not $self->options->{'is_compress'} or not $compressed and ($self->request->content_encoding || '') =~ /\S/
422 0 0 if not $SOAP::Constants::DO_NOT_CHECK_CONTENT_TYPE and $content_type and $content_type ne 'application/soap+xml' and $content_type ne 'text/xml' and $content_type ne 'application/dime' and not $content_type =~ m[^multipart/]
434 0 0 if (defined $self->request->header('Expect') and $self->request->header('Expect') eq '100-Continue')
441 0 0 $compressed ? :
446 0 0 $self->request->content_type =~ m[^multipart/] ? :
0 0 unless my $response = $self->SUPER::handle($self->request->content_type =~ m[^multipart/] ? join("\n", $self->request->headers_as_string, $content) : $content)
468 0 0 if $response =~ /^<\?xml(?: version="1.0"| encoding="([^\"]+)")+\?>/
471 0 0 if $self->request->content_type eq 'multipart/form-data'
484 0 0 if $compressed
504 0 0 $compressed ? :
0 0 !$SOAP::Constants::DO_NOT_USE_CHARSET && $encoding ? :
0 0 $] > 5.007 ? :
508 0 0 if $is_multipart
531 0 0 if ref $self
558 0 0 if ($chunked)
567 0 0 if (not $length) { }
0 0 elsif (defined $SOAP::Constants::MAX_CONTENT_SIZE and $length > $SOAP::Constants::MAX_CONTENT_SIZE) { }
575 0 0 if (exists $ENV{'EXPECT'} and $ENV{'EXPECT'} =~ /\b100-Continue\b/i)
580 0 0 unless ($chunked)
583 0 0 if (defined $ENV{'MOD_PERL'}) { }
586 0 0 if length $content >= $length
591 0 0 if length $content >= $length
597 0 0 $1 =~ /SOAPACTION/ ? :
0 0 /^HTTP_(.+)/i ? :
615 0 0 defined $ENV{'SERVER_SOFTWARE'} && $ENV{'SERVER_SOFTWARE'} =~ /IIS/ ? :
642 0 0 if ref $self
648 0 0 $class->can($_[0]) ? :
656 0 0 if not $self->SSL and grep /^SSL_/, @params
658 0 0 unless $http_daemon->can('new')
662 0 0 unless $$self{'_daemon'} = $http_daemon->new(@params)
671 0 0 ref $params eq 'ARRAY' ? :
684 0 0 if (@_)
691 0 0 (shift())->SSL ? :
695 0 0 if $method eq 'DESTROY'
712 0 0 if ($@ and not $@ =~ /^SIGPIPE/)
719 0 0 $c->can('shutdown') ? :
737 0 0 unless (ref $self)
748 0 0 if (defined $ENV{'MOD_PERL_API_VERSION'} and $ENV{'MOD_PERL_API_VERSION'} >= 2) { }
761 0 0 unless eval 'require mod_perl'
763 0 0 unless defined $mod_perl::VERSION
765 0 0 if ($mod_perl::VERSION < 1.99) { }
792 0 0 unless ($r)
793 0 0 if ($$self{'MOD_PERL_VERSION'} < 2) { }
802 0 0 if ($$self{'MOD_PERL_VERSION'} < 2) { }
812 0 0 if ($cont_len > 0) { }
821 0 0 if $$self{'MOD_PERL_VERSION'} >= 2
827 0 0 if ($$self{'MOD_PERL_VERSION'} < 2) { }
847 0 0 if ($$self{'MOD_PERL_VERSION'} < 2) { }
855 0 0 if ($$self{'MOD_PERL_VERSION'} > 1) { }
874 0 0 ref $self->$_ ? :
0 0 $$config{$_} =~ /=>/ ? :
0 0 if $self->can($_)
913 0 0 if ref $class