Branch Coverage

blib/lib/Cz/Cstocs.pm
Criterion Covered Total %
branch 100 150 66.6


line true false branch
25 1 1 if (@data)
30 0 1 if grep {$_ eq $fn;} @Cz::Cstocs::EXPORT_OK
32 0 1 unless defined $out
34 0 1 unless defined $fnref
37 0 1 if ($@)
108 14 5 if defined $input_hashes{$enc}
110 0 5 if ($enc eq 'mime')
112 0 0 if ($@)
119 0 5 unless open FILE, $file
120 0 5 if &DEBUG()
125 7 804 if /^(#|\s*$)/
127 0 804 unless (defined $tag and defined $desc)
132 779 25 if ($tag =~ /^\d+|0x\d+$/)
134 468 502 /^0/ ? :
138 795 9 unless defined $output->{$desc}
145 1 4 if ($enc eq 'tex')
153 0 1 if &DEBUG()
163 95 0 unless defined $output->{$tag}
174 18 6 if $tag =~ /[a-zA-Z]$/
176 16 8 if ($az and $output->{$value} eq $tag)
181 10 14 if (grep {$_ eq $value;} @diacritics) { }
13 1 elsif ($az) { }
183 5 5 if ($az) { }
216 1 0 if (@dialetters)
221 1 0 if (@dianonletters)
222 1 0 if $regexp ne ''
227 1 0 if (@nondialetters)
228 1 0 if $regexp ne ''
233 1 0 if (@nondianonletters)
234 1 0 if $regexp ne ''
246 7 1 if $accent_read
250 0 1 unless open FILE, $file
251 0 1 if &DEBUG()
255 0 201 if /^\s*(#|$)/
257 0 201 unless (defined $key and defined $val)
269 21 1 if $alias_read
273 0 1 unless open FILE, $file
288 2 20 defined $alias{$enc} ? :
297 294 0 if (defined $outenc->{$desc}) { }
0 0 elsif (defined $accent->{$desc}) { }
318 0 11 unless (defined $inputenc and defined $outputenc)
330 2 9 if $inputenc eq 'tex'
335 0 3 if &DEBUG()
336 1 2 if $tag eq 'fillstring'
337 1 0 defined $value ? :
1 2 if $tag eq 'use_accent'
339 0 0 $value ? :
0 0 defined $value ? :
0 3 if $tag eq 'nofillstring'
342 0 3 if $tag eq 'cstocsdir'
343 1 2 if $tag eq 'one_by_one'
350 2 9 if (defined $functions{"${inputenc}_${outputenc}_${fillstring}_${use_fillstring}_${use_accent}_$one_by_one"})
357 8 1 if $use_accent
359 0 9 if ($@)
368 9 0 if ($outputenc ne 'mime')
374 928 2183 if (not defined $output and $use_accent)
380 229 699 if defined $accent{$desc}
382 0 928 if ($@)
387 11 10 if $one_by_one and defined $output and length $key < length $output
390 11 3100 if (not defined $output and $use_fillstring)
394 1438 1673 if not defined $output or $inputenc ne 'utf8' and $key eq $output
396 1419 254 if (length $key != 1 or length $output != 1)
404 0 9 if ($inputenc eq 'mime') { }
0 9 elsif ($outputenc eq 'mime') { }
1 8 elsif (not keys %$conv) { }
1 7 elsif ($is_one_by_one) { }
2 5 elsif ($inputenc eq 'tex') { }
1 4 elsif ($inputenc eq 'utf8') { }
427 0 0 unless (defined $charset)
456 4 0 if ($singles ne '[]')
457 0 4 unless $src eq ''
466 0 9 if &DEBUG()
469 0 9 if ($@)
484 0 1 unless opendir DIR, $Cz::Cstocs::cstocsdir
499 0 0 if defined $output_hashes{$encoding}{$name}