Branch Coverage

lib/Perl/PrereqScanner/NotQuiteLite/Parser/Core.pm
Criterion Covered Total %
branch 68 88 77.2


line true false branch
82 9 11 if $token->[1] eq "COMMA"
87 4 0 if (ref $module and $module->[1] eq 'WORD' || $module->[1] eq 'KEYWORD')
90 9 0 if (is_module_name($module)) { }
91 0 9 if (is_version($tokens->[0])) { }
106 0 25 if (is_version($tokens->[0]))
111 2 57 if (ref $module and ($module->[1] || '') eq "WORD")
114 1 1 if @$tokens and ref $tokens->[0] and ($tokens->[0][1] || '') eq "()"
117 3 55 if (ref $module and ref $module->[0])
120 29 29 if (is_module_name($module))
130 0 28 if (is_version($tokens->[0]))
134 2 52 if $token eq "-norequire"
136 31 21 if (ref $token)
137 5 26 if $token->[0] eq "-norequire"
139 2 45 if (ref $module and ($module->[1] || '') eq "WORD")
142 1 1 if @$tokens and ref $tokens->[0] and ($tokens->[0][1] || '') eq "()"
145 3 43 if (ref $module and ref $module->[0])
148 23 23 if is_module_name($module)
155 38 16 if ($used_module eq 'feature') { }
16 0 elsif ($used_module eq 'experimental') { }
161 0 54 if (is_version($tokens->[0]))
165 57 51 if ref $token
167 10 41 if ($token eq "class")
170 47 4 if (exists $feature_since{$token})
174 4 0 if ($token =~ /^:5\.([0-9]+)(\.\[0-9]+)?/)
186 0 5 if (is_version($tokens->[0]))
190 6 4 if ref $token
192 4 0 if (exists $builtin_since{$token})
202 0 8 unless $c->{'stack'}
203 7 0 if $_->[0] eq "{"
4 4 if (grep {$_->[2] eq "BEGIN" if $_->[0] eq "{";} @stack)
204 1 3 if (grep {$c->token_is_conditional($_->[0]);} @$raw_tokens) { }
1 2 elsif (grep {$c->token_is_conditional($_->[2]) if $_->[0] eq '{';} @stack) { }
206 4 0 if $_->[0] eq "{"
221 31 1 if (ref $token and $token->[1] and $token->[1] eq "WORD")
224 32 0 if (@$tokens)
226 5 27 if (is_version($token))
230 6 26 if (ref $token and $token->[1] and $token->[1] =~ /^\{/)
276 10 12 if (ref $token and $token->[1] and $token->[1] eq "WORD")
277 10 0 if (is_module_name($token->[0]))
279 5 5 if (@$tokens and is_version($tokens->[0]))
285 8 14 if (ref $token and $token->[1] and $token->[1] eq "ATTRIBUTE")
289 8 0 if (is_module_name($name) and is_version($version))
305 0 0 if (is_module_name($token->[0]))
307 0 0 if (@$tokens and is_version($tokens->[0]))