Branch Coverage

blib/lib/Text/Extract/MaketextCallPhrases.pm
Criterion Covered Total %
branch 127 148 85.8


line true false branch
33 0 58 if ($$conf_hr{'encode_unicode_slash_x'})
34 0 0 unless Module::Want::have_mod('Encode')
37 1 57 if ($$conf_hr{'cpanel_mode'} and $$conf_hr{'cpanel_mode'} != 0)
47 10 3 $$conf_hr{'no_default_regex'} ? :
13 45 $$conf_hr{'regexp_conf'} ? :
58 9 56 defined $$regexp[2] && ref $$regexp[2] eq 'HASH' ? :
59 62 3 exists $$rx_conf_hr{'arg_position'} ? :
66 4 509 if ($matched eq '## no extract maketext')
77 6 503 if $text_working_copy =~ s/^[^\n]*## no extract maketext[^\n]*//
84 6 497 if ($$conf_hr{'ignore_perlish_comments'})
87 2 4 if ($pre =~ /\#/ and not $pre =~ /[\n\r]$/)
90 1 1 if ($lines[-1] =~ /\#/)
92 0 1 if defined $linenum
100 4 498 if ($text_working_copy =~ /^\s*\{/ and not $matched =~ /\(\s*$/)
102 0 4 if defined $linenum
108 2 496 if ($text_working_copy =~ /^\s*=/)
110 0 2 if defined $linenum
115 3 493 if ($$conf_hr{'ignore_perlish_statement'})
118 1 2 if ($text_working_copy =~ /^\s*;/)
120 0 1 if defined $linenum
127 25 470 if ($$rx_conf_hr{'arg_position'} > 0)
132 25 30 if ($at_index >= $$rx_conf_hr{'arg_position'})
139 30 0 unless (defined $phrase)
146 3 488 $text_working_copy =~ /^\s*\{/ ? :
4 491 $text_working_copy =~ /^\s*\[/ ? :
151 465 30 if (not $phrase) { }
156 0 465 unless defined $text_working_copy
158 189 161 if defined $opener and $opener eq q['] or defined $type and $type eq 'q' || $type eq 'qw'
159 97 368 if defined $opener and $opener eq '"' or defined $type and $type eq 'qq'
160 286 179 if ($$result_hr{'quotetype'})
165 22 443 if (defined $type and $type eq '<<')
170 19 3 if (substr($opener, 0, 1) eq q[']) { }
178 30 435 if (defined $inside and exists $$result_hr{'quotetype'} and $inside eq '') { }
320 115 elsif (defined $inside and $inside) { }
0 115 elsif (defined $opener and defined $inside and defined $closer and defined $phrase and $phrase eq "$opener$inside$closer") { }
186 21 299 if ($type eq 'qw') { }
12 287 elsif ($type eq 'qx' or $opener eq '`') { }
30 257 elsif ($type eq 'm' or $type eq 'qr' or $type eq 's' or $type eq 'tr' or $opener eq '/') { }
187 2 19 if ($phrase =~ /\A(\s+)/)
191 2 19 if ($phrase =~ /(\s+)\z/)
196 19 2 if ($phrase =~ /(\s+)/)
220 115 0 if (defined $$regexp[1])
221 89 26 if (ref $$regexp[1] eq 'CODE') { }
26 0 elsif (ref $$regexp[1] eq 'Regexp') { }
223 37 52 if ($text_working_copy =~ /^$rgx/)
229 15 11 if ($text_working_copy =~ /$rgx/)
235 52 63 if ($is_no_arg) { }
44 19 elsif ($text_working_copy =~ /^\s*(((?:\&|\\\*)?)$ns_regexp(?:\-\>$ns_regexp)?((?:\s*\()?))/o) { }
236 13 39 if ($$rx_conf_hr{'optional'}) { }
246 18 26 $2 || $3 ? :
251 18 26 $perlish ? :
260 58 424 if (not defined $phrase) { }
262 58 0 if (defined $$regexp[1])
263 49 9 if (ref $$regexp[1] eq 'CODE') { }
9 0 elsif (ref $$regexp[1] eq 'Regexp') { }
265 37 12 if ($text_working_copy =~ /^$rgx/)
271 2 7 if ($text_working_copy =~ /$rgx/)
277 39 19 if ($is_no_arg) { }
278 0 39 if ($$rx_conf_hr{'optional'}) { }
287 7 12 if ($optional_perlish) { }
288 3 4 if ($$rx_conf_hr{'optional'}) { }
309 34 390 if ($var and defined $for and defined $aft and $for =~ /\A\s*\z/ and $aft =~ /\A\s*\z/) { }
314 304 86 if (exists $$result_hr{'quotetype'})
315 206 98 if ($$result_hr{'quotetype'} eq 'single') { }
98 0 elsif ($$result_hr{'quotetype'} eq 'double') { }
327 0 390 if ($$conf_hr{'encode_unicode_slash_x'}) { }
340 372 18 unless exists $$result_hr{'type'} and $$result_hr{'type'} eq 'perlish'
346 479 0 if ++$offset_seen{$$result_hr{'offset'}} == 1
356 0 1 unless open my $fh, '<', $file
368 6 3 $in_multi_line ? :
371 0 12 if ($in_multi_line and $updated_result_count == $initial_result_count) { }
4 8 elsif ($in_multi_line and $updated_result_count > $initial_result_count and $results[-1]{'type'}) { }
2 6 elsif (not $in_multi_line and @results and defined $results[-1]{'type'} and $results[-1]{'type'} eq 'multiline') { }
385 0 2 $$trailing_partial{'offset'} > &bytes::length($prepend . $line) ? :