| blib/lib/PAGI/Middleware/JSONBody.pm | |||
|---|---|---|---|
| Criterion | Covered | Total | % |
| branch | 17 | 24 | 70.8 |
| line | true | false | branch |
|---|---|---|---|
| 66 | 0 | 5 | if ($scope->{'type'} ne "http") |
| 75 | 1 | 4 | unless ($is_json) |
| 86 | 0 | 4 | unless $event and $event->{'type'} |
| 88 | 4 | 0 | if ($event->{'type'} eq 'http.request') { } |
| 0 | 0 | elsif ($event->{'type'} eq 'http.disconnect') { } | |
| 90 | 1 | 3 | if (length $body > $self->{'max_size'}) |
| 94 | 3 | 0 | unless $event->{'more'} |
| 101 | 1 | 3 | if ($too_large) |
| 111 | 1 | 2 | if ($@) |
| 141 | 3 | 4 | if index($content_type, $lc_pattern) == 0 |
| 145 | 1 | 1 | if $content_type =~ m[^application/[^;]+\+json] |
| 155 | 5 | 0 | if lc $h->[0] eq $name |