Condition Coverage

blib/lib/SQL/SplitStatement.pm
Criterion Covered Total %
condition 145 176 82.3


and 3 conditions

line !l l&&!r l&&r condition
169 56597 739 758 $self->_is_comment($token) and not $self->keep_comments
193 30068 7 335 $prev_token =~ /$AS_RE/ and not $dollar_quote
30075 295 40 $prev_token =~ /$AS_RE/ and not $dollar_quote and $dollar_quote = $self->_dollar_quote_open_found($token)
30329 0 41 $token =~ /$DELIMITER_RE/ and not $prev_token
24898 28 3 $token =~ /$BODY_RE/ and $prev_token =~ /$TYPE_RE/
15017 8306 98 $inside_crud and my $placeholder_token = $self->_questionmark_placeholder_found($token) || $self->_named_placeholder_found($token) || $self->_dollar_placeholder_found($token)
244 323 10 139 $prev_keyword =~ /$PROCEDURE_FUNCTION_RE|$BODY_RE/ and not $inside_block
333 0 139 $prev_keyword =~ /$PROCEDURE_FUNCTION_RE|$BODY_RE/ and not $inside_block and not $prev_token =~ /$pre_identifier_RE/
252 458 10 4 $inside_declare and $inside_cursor
262 20 0 13 $inside_declare and not $prev_token =~ /$DROP_RE/
20 0 13 $inside_declare and not $prev_token =~ /$DROP_RE/ and not $prev_token =~ /$pre_identifier_RE/
281 56 0 35 $inside_sub and $inside_is_as
293 111 0 127 $inside_sub and @sub_names
111 51 76 $inside_sub and @sub_names and $name eq $sub_names[-1]
298 138 71 29 $inside_package and $name eq $package_name
328 21422 90 1811 $terminator_found and $terminator_found == 1
21512 0 1811 $terminator_found and $terminator_found == 1 and not $inside_brackets
332 1131 607 73 $inside_sub and not $inside_is_as
1738 0 73 $inside_sub and not $inside_is_as and not $inside_block
338 1458 320 33 $inside_declare and $inside_cursor
1778 24 9 $inside_declare and $inside_cursor and not $inside_is_cursor
348 0 739 29671 $token =~ /\S/ and not $self->_is_comment($token)
353 28468 1869 32 $terminator_found and $terminator_found == 3
364 0 55 1546 $terminator_found and $terminator_found == 1
55 873 673 $terminator_found and $terminator_found == 1 and $inside_block || $inside_sub || $inside_declare || $inside_package || $inside_crud
873 0 673 $terminator_found and $terminator_found == 1 and $inside_block || $inside_sub || $inside_declare || $inside_package || $inside_crud and not $inside_grant_revoke
873 0 673 $terminator_found and $terminator_found == 1 and $inside_block || $inside_sub || $inside_declare || $inside_package || $inside_crud and not $inside_grant_revoke and not $extra_end_found
427 57 486 14 $terminator->[0] && $terminator->[0] == 3
472 25879 18 216 $token =~ /$BEGIN_RE/ && !($prev_token =~ /$pre_identifier_RE/) && !($self->_peek_at_next_significant_token =~ /$transaction_RE/)
482 0 252 90 defined $next_token && $next_token =~ /$procedural_END_RE/
23969 90 252 $token =~ /$END_RE/ and not defined $next_token && $next_token =~ /$procedural_END_RE/
538 0 0 4 $tokens->[0] =~ /^$inner_identifier_RE$/ and $tokens->[1] eq '$'
657 125 1842 19917 $token ne '/' and $token ne ';'
668 0 28 0 $next_token =~ /^\s+$/ and $next_next_token eq "\n"
683 3 0 36 $self->slash_terminates and $current_statement =~ /\n\s*\z/
3 6 30 $self->slash_terminates and $current_statement =~ /\n\s*\z/ and $next_significant_token_idx == -1 || $tokens->[$next_significant_token_idx] ne '(' && !($tokens->[$next_significant_token_idx] =~ /^\d/) && !($tokens->[$next_significant_token_idx] eq '.' && $$tokens[$next_significant_token_idx + 1] =~ /^\d/)
705 1787 55 16290 $i <= 8 and defined $tokens->[$i]
708 0 52 1790 $token eq ';' and not $next_code_portion =~ m[\A\s*\n\s*/\s*$]m
52 6 1784 $token eq ';' and not $next_code_portion =~ m[\A\s*\n\s*/\s*$]m and not $next_code_portion =~ m[\A\s*\n\s*\.\s*\n\s*/\s*$]m
723 927 2 922 /\S/ and not $self->_is_comment($_)
739 0 0 0 /\S/ and not $self->_is_comment($_)

or 2 conditions

line l !l condition
105 11 31 $_[0] || {}

or 3 conditions

line l !l&&r !l&&!r condition
193 252 0 24929 $token =~ /$PROCEDURE_FUNCTION_RE/ or $token =~ /$BODY_RE/ and $prev_token =~ /$TYPE_RE/
32 66 8306 $self->_questionmark_placeholder_found($token) || $self->_named_placeholder_found($token) || $self->_dollar_placeholder_found($token)
233 0 10 245 $inside_block or $inside_brackets
10 14 231 $inside_block or $inside_brackets or $prev_token =~ /$DROP_RE/
14 5 226 $inside_block or $inside_brackets or $prev_token =~ /$DROP_RE/ or $prev_token =~ /$pre_identifier_RE/
257 31 10 61 $inside_block or $prev_token =~ /$pre_identifier_RE/
315 98 0 0 not $self->_custom_delimiter or $self->_custom_delimiter ne $placeholder_token
353 41 1848 28521 $custom_delimiter_def_found or $terminator_found and $terminator_found == 3
360 28468 268 1601 not $terminator_found or $dollar_quote
28736 0 1601 not $terminator_found or $dollar_quote or $inside_brackets
268 0 1601 not $terminator_found or $dollar_quote or $inside_brackets or $self->_custom_delimiter
364 168 0 873 $inside_block || $inside_sub || $inside_declare || $inside_package || $inside_crud
380 873 55 73 $terminator_found == 1 or $terminator_found == 2
668 0 97 28 not defined $next_token or $next_token eq "\n"
97 0 28 not defined $next_token or $next_token eq "\n" or $next_token =~ /^\s+$/ and $next_next_token eq "\n"
673 52 6 39 $current_statement =~ /;\s*\n\s*\z/ or $current_statement =~ /\n\s*\.\s*\n\s*\z/
683 3 28 5 $next_significant_token_idx == -1 || $tokens->[$next_significant_token_idx] ne '(' && !($tokens->[$next_significant_token_idx] =~ /^\d/) && !($tokens->[$next_significant_token_idx] eq '.' && $$tokens[$next_significant_token_idx + 1] =~ /^\d/)