Branch Coverage

blib/lib/XAO/Web.pm
Criterion Covered Total %
branch 66 136 48.5


line true false branch
140 0 84 unless ref $patharr
150 84 0 if ($table)
152 167 81 $i ? :
158 245 3 unless defined $od
168 3 0 if (ref $od eq 'HASH') { }
0 0 elsif (ref $od eq 'ARRAY') { }
170 0 3 if ($type eq 'default') { }
3 0 elsif ($type eq 'xaoweb') { }
0 0 elsif ($allow_other_types) { }
0 0 elsif ($od->{'xaoweb'} and ref $od->{'xaoweb'} eq 'HASH') { }
174 0 3 unless ($od->{'objname'})
190 0 0 unless @$od
192 0 0 if (scalar(@{$od;}) % 2 == 1) { }
205 0 0 unless length $od
227 80 1 if ($filename)
304 0 11 if ($args->{'apache'}) { }
0 11 elsif ($args->{'psgi'}) { }
334 0 0 if ($e->isa("APR::Error"))
349 0 0 if ($pd and $pd->{'type'} eq 'xaoweb' and $pd->{'objname'} ne 'Default') { }
366 0 0 if $old_logprint_handler
382 11 0 if (defined $header)
383 0 11 if (my $env = $args->{'psgi'}) { }
0 11 elsif (my $r = $args->{'apache'}) { }
396 0 0 if ($mod_perl::VERSION and $mod_perl::VERSION >= 1.99) { }
405 0 0 unless $r->content_type
415 0 0 unless $r->header_only
429 0 11 if $old_logprint_handler
481 0 71 if (wantarray) { }
500 138 23 if (not $autolist) { }
23 0 elsif (ref $autolist eq 'ARRAY') { }
0 0 elsif (ref $autolist eq 'HASH') { }
513 1 27 if $clipboard->get("_no_more_output")
565 82 0 unless ($pd)
567 0 82 unless @path
568 0 82 if $path =~ m[/$]
583 7 75 unless ($cgi)
584 0 7 if $args->{'psgi'}
588 0 82 if ($apache) { }
592 82 0 if (defined $CGI::VERSION and $CGI::VERSION >= 2.8) { }
597 64 18 if ($pinfo =~ m[^/\Q$sitename\E(/.+)?\Q$uri\E]) { }
0 36 elsif ($pinfo and $uri =~ /^(.*)\Q$pinfo\E$/) { }
608 0 0 if $active_url =~ /^(.*)(\Q$path\E)$/
615 0 82 if ($active_url =~ /cgi-bin/ or $active_url =~ /xao-[\w-]+\.pl/)
629 48 34 if ($active_url =~ m[^http:(//.*)$]) { }
34 0 elsif ($active_url =~ m[^https:(//.*)$]) { }
651 82 0 if ($siteconfig->defined('base_url')) { }
653 0 82 unless $url =~ /^http:/i
657 0 82 if $nu ne $url
660 0 82 unless ($url)
676 0 82 $apache || $ENV{'MOD_PERL'} ? :
684 82 0 if ($charset)
685 82 0 if ($cgi->can('set_param_charset')) { }
712 81 1 if ($urlstyle eq 'files') { }
1 0 elsif ($urlstyle eq 'raw') { }
713 2 79 unless ($pd->{'patharr'}[-1] =~ /\.\w+$/)
716 1 1 if ($pd->{'objname'} ne "Default")
717 0 1 $active_is_secure ? :
736 0 81 if (&XAO::Utils::get_debug() and not $args->{'quieter'})
767 80 1 unless ($clipboard->get("_no_more_output"))
799 8 235 &Encode::is_utf8($_) ? :
837 38 0 unless ($siteconfig)
869 0 38 if $args->{'cgi'}
877 38 0 if ($url)
878 0 38 unless $url =~ /^http:/i
882 0 38 if $nu ne $url
885 38 0 unless ($url)
912 0 0 unless ($pdtc)
955 0 202 unless $self->{'sitename'}