Branch Coverage

blib/lib/Lim/RPC/Protocol/JSONRPC1.pm
Criterion Covered Total %
branch 10 36 27.7


line true false branch
74 0 1 unless (blessed $request and $request->isa('HTTP::Request'))
78 1 0 if ($request->header('Content-Type') =~ m[(?:^|\s)application/json(?:$|\s|;)]ou and $request->uri =~ m[^/([a-zA-Z]+)\s*$]ou)
86 1 0 if (defined $server and $server->have_module($module)) { }
92 1 0 unless ($@)
93 1 0 if (ref $jsonreq eq 'HASH' and exists $$jsonreq{'id'} and exists $$jsonreq{'method'}) { }
97 1 0 if ($server->have_module_call($module, $call)) { }
106 0 1 unless (defined $self)
110 0 1 if (blessed $result and $result->isa('Lim::Error')) { }
1 0 elsif (ref $result eq 'HASH') { }
122 0 0 if ($@) { }
124 0 0 if Lim::WARN()
142 0 1 if ($@) { }
144 0 0 if Lim::WARN()
192 0 0 if ($@ and not defined $jsonresp)
203 0 0 if (defined $jsonresp) { }
0 0 elsif (not $response->code) { }
207 0 0 if ($@)
209 0 0 if Lim::WARN()