Condition Coverage

blib/lib/ClearPress/view.pm
Criterion Covered Total %
condition 79 123 64.2


and 3 conditions

line !l l&&!r l&&r condition
120 0 0 0 $lang and not $ClearPress::view::LEXICON_CACHE->{$lang}
187 6 1 1 $action eq 'read' and not $aspect =~ /^(?:add|edit|delete|update|create)/msx
199 0 4 3 $requestor->can('is_member_of') and $requestor->is_member_of('admin')
257 3 32 1 $pk and $method eq 'read'
35 0 1 $pk and $method eq 'read' and not $model->$pk
493 20 0 0 ref $params->{$k} and ref $params->{$k} eq 'HASH'
20 0 0 ref $params->{$k} and ref $params->{$k} eq 'HASH' and not scalar keys %{$$params{$k};}
517 4 0 0 ref $params->{$k} and ref $params->{$k} eq 'HASH'
4 0 0 ref $params->{$k} and ref $params->{$k} eq 'HASH' and not scalar keys %{$$params{$k};}
608 0 0 320 $name and $code
703 0 0 14 scalar @args == 2 and $args[1] eq "\n"
0 14 0 scalar @args == 2 and $args[1] eq "\n" and not $args[0]
715 30 0 1 scalar @args == 2 and $args[1] eq "\n"
30 1 0 scalar @args == 2 and $args[1] eq "\n" and not $args[0]

or 2 conditions

line l !l condition
39 77 3 $self ||= {}
51 52 28 $self->aspect || ''
69 28 52 $self->{'content_type'} ||= 'text/html'
71 1 79 $self->{'charset'} ||= 'UTF-8'
175 25 0 $self->action || ''
176 18 7 $self->aspect || ''
223 14 6 $name ||= 'view'
287 15 2 $self->aspect || ''
374 15 0 $warnings . $actions . $content || 'No data'
382 35 0 $entity ||= ''
383 0 35 $ENV{'SCRIPT_NAME'} || ''
385 23 12 ($xfh ? $xfh : $ENV{'HTTP_HOST'}) || 'localhost'
386 0 35 ($xfh ? $xfp : $ENV{'HTTP_PORT'}) || ''
422 31 4 $ClearPress::view::TEMPLATE_CACHE->{$appname} ||= {}
669 46 3 $self->aspect || ''

or 3 conditions

line l !l&&r !l&&!r condition
53 0 18 62 $self->{'content_type'} ||= $aspect =~ /(?:rss|atom|ajax|xml)$/msx ? 'text/xml' : ''
54 18 6 56 $self->{'content_type'} ||= $aspect =~ /(?:js|json)$/msx ? 'application/json' : ''
55 24 0 56 $self->{'content_type'} ||= $aspect =~ /_svg$/msx ? 'image/svg+xml' : ''
56 24 0 56 $self->{'content_type'} ||= $aspect =~ /_svgz$/msx ? 'image/svg+xml' : ''
57 24 2 54 $self->{'content_type'} ||= $aspect =~ /_png$/msx ? 'image/png' : ''
58 26 2 52 $self->{'content_type'} ||= $aspect =~ /_jpg$/msx ? 'image/jpeg' : ''
59 28 0 52 $self->{'content_type'} ||= $aspect =~ /_txt$/msx ? 'text/plain' : ''
60 28 0 52 $self->{'content_type'} ||= $aspect =~ /_csv$/msx ? 'text/csv' : ''
61 28 0 52 $self->{'content_type'} ||= $aspect =~ /_xls$/msx ? 'application/vnd.ms-excel' : ''
72 31 49 0 $self->{'headers'} ||= 'HTTP::Headers'->new
133 0 0 0 $loc || $string
187 1 1 7 $action =~ /^list/msx or $action eq 'read' and not $aspect =~ /^(?:add|edit|delete|update|create)/msx
249 29 7 1 $aspect || $action
322 0 0 17 $aspect eq 'options' or $aspect =~ /_(?:jpg|png|gif|svg|svgz)/msx
387 0 0 35 $ENV{'HTTP_X_FORWARDED_PROTO'} || $ENV{'HTTPS'}
420 35 0 0 $util->config->val('application', 'name') || $util->config->val('application', 'namespace') || $ENV{'SCRIPT_NAME'}
644 9 0 0 $util->config->val('application', 'namespace') || $util->config->val('application', 'name')