Branch Coverage

blib/lib/PPI/Token/Word.pm
Criterion Covered Total %
branch 58 72 80.5


line true false branch
80 4 7 if ($previous and $previous->isa("PPI::Token::Operator") and $previous->content eq "->")
91 3 15 unless $snext
93 8 1 if ($snext->isa("PPI::Structure::List") or $snext->isa("PPI::Token::Structure") or $snext->isa("PPI::Token::Operator") and $snext->content eq ',' || $snext->content eq '=>')
108 1 5 if ($snext->isa("PPI::Token::Word") and $snext->content =~ / \w :: \z /msx)
126 11 7 if ($t->{'line'} =~ /\G(\w+(?:(?:\'|::)\w+)*(?:::)?)/cg)
131 1 0 if ($word =~ /^(\w+)'/ and $PPI::Token::Word::KEYWORDS{$1})
140 0 18 if (__current_token_is_attribute($t))
146 0 18 if ($PPI::Token::Word::KEYWORDS{$word})
148 0 0 if ($t->__current_token_is_forced_word)
154 0 0 if ($PPI::Token::Word::QUOTELIKE{$word})
160 0 0 if ($PPI::Token::Word::OPERATOR{$word})
168 10 8 if ($word =~ /\:/)
175 0 8 if ($char eq ':') { }
1 7 elsif ($word eq '_') { }
200 0 56605 unless ($t->{'line'} =~ /\G((?!\d)\w+(?:(?:\'|::)\w+)*(?:::)?)/cg)
208 260 53 if ($word =~ /^(\w+)'/ and $PPI::Token::Word::KEYWORDS{$1})
216 1065 55540 if (__current_token_is_attribute($t))
219 0 1065 $t->{'line_cursor'} >= $t->{'line_length'} ? :
223 8 55532 if ($word eq "__END__")
236 6 2 if ($end_rest =~ /\n$/) { }
238 1 5 if length $end_rest
241 1 1 if length $end_rest
249 6 55526 if ($word eq "__DATA__")
260 4 2 if ($data_rest =~ /\n$/) { }
262 1 3 if length $data_rest
265 1 1 if length $data_rest
273 1293 54233 if ($word =~ /\:/) { }
6624 47609 elsif ($PPI::Token::Word::KEYWORDS{$word} and $t->__current_token_is_forced_word) { }
2611 44998 elsif ($PPI::Token::Word::QUOTELIKE{$word}) { }
1648 43350 elsif ($PPI::Token::Word::OPERATOR{$word} and $word ne 'x' || $t->_current_x_is_operator) { }
284 0 2611 $t->{'line_cursor'} >= $t->{'line_length'} ? :
296 1374 41976 if ($t->{'line'} =~ /\G(\s*:)(?!:)/cg) { }
433 41543 elsif ($word eq '_') { }
297 624 750 if ($tokens[0] and $tokens[0]{'content'} eq 'sub') { }
442 308 elsif (not $tokens[0] && $tokens[0]->isa('PPI::Token::Operator')) { }
324 0 52915 if ($t->{'line_cursor'} >= $t->{'line_length'})