Branch Coverage

blib/lib/Catalyst/View/JSON/_PerRequest.pm
Criterion Covered Total %
branch 21 40 52.5


line true false branch
8 4 38 if ($data) { }
9 0 4 if ($self->{'data'}) { }
12 1 3 unless ref $data
21 4 0 unless ref $default_view_model
30 1 2 if (defined $value)
38 0 0 if (defined $value)
50 8 0 if (ref \$proto[0] eq 'SCALAR' and &Scalar::Util::looks_like_number($proto[0])) { }
58 5 3 if (scalar @proto and ref $proto[$#proto] eq 'HASH') { }
3 0 elsif (scalar @proto and &Scalar::Util::blessed($proto[$#proto])) { }
64 9 0 if ($self->data->can('set')) { }
78 0 8 if (@proto)
83 0 0 $status ? :
0 8 if $self->{'ctx'}->debug
88 0 6 if @headers
89 6 0 unless $res->status != 200
90 6 0 unless $res->content_type
92 0 6 if (my $param = $self->{'callback_param'})
94 0 0 unless $cb =~ /^[a-zA-Z0-9\.\_\[\]]+$/
98 6 0 unless $res->has_body
99 0 6 if $self->{'auto_detach'}