Branch Coverage

blib/lib/JSON5/Parser.pm
Criterion Covered Total %
branch 73 74 98.6


line true false branch
19 8 4 $_[0] eq 'true' ? :
22 4 2 $_[0] eq '+' ? :
32 2 17 @_ ? :
49 5 1 if @_
65 2 108 if (my $max_size = $self->{'max_size'})
68 1 1 unless $bytes <= $max_size
71 83 26 if ($self->{'utf8'})
90 95 14 if m[\G(?:\s*|//.*$|/\*.*?\*/)*\z]cgms
95 1059 24 unless m[\G//.*$]cgm
105 112 252 if ($self->_parse_object_or_array) { }
252 0 elsif ($allow_nonref) { }
109 122 130 if ($self->_parse_number) { }
12 118 elsif ($self->_parse_boolean) { }
90 28 elsif ($self->_parse_string) { }
7 21 elsif (/\Gnull/cgm) { }
130 80 284 if (/\G\{/cgm) { }
45 239 elsif (/\G\[/cgm) { }
149 17 136 if (/\G\}/cgm)
156 2 127 unless ($self->_parse_string or $self->_parse_identifier)
165 1 133 unless (/\G\:/cgm)
172 3 130 unless ($self->_parse_value)
185 55 75 if (/\G\}/cgm) { }
73 2 elsif (/\G,/cgm) { }
202 19 122 if (/\G\]/cgm)
209 4 118 unless ($self->_parse_value)
222 21 97 if (/\G\]/cgm) { }
96 1 elsif (/\G,/cgm) { }
235 10 242 if (/\G([-+])?Infinity/cgm) { }
3 239 elsif (/\GNaN/cgm) { }
16 223 elsif (/\G([-+]?)0x([0-9a-f]+)/cgim) { }
93 130 elsif (/\G([-+]?(?:[0-9]+(?:\.[0-9]*)?|[0-9]*\.[0-9]+))(?:e([-+]?[0-9]+))?/cgm) { }
247 2 14 if $1 and $1 eq '-'
253 5 88 if defined $2
264 12 118 if (/\G(true|false)/cgm)
276 97 157 if (/\G(?:"((?:.|(?<=\\)\n)*?)(?
309 127 2 if (/\G([a-z_\$][0-9a-z_\$]*)/cgim)
330 4 10 if $len > 0