Branch Coverage

blib/lib/HTML/Tidy.pm
Criterion Covered Total %
branch 43 48 89.5


line true false branch
111 3 20 if ($key eq 'config_file')
119 0 20 if (grep {$newkey eq $_;} @unsupported_options)
195 1 13 ref $value eq 'ARRAY' ? :
197 1 13 unless $parm eq 'text' or $parm eq 'type'
221 0 10 if (@_ == 0)
226 1 9 if utf8::is_utf8($html)
228 2 8 unless defined $errorblock
249 151 29 if ($line =~ /^line (\d+) column (\d+) - (Warning|Error|Info): (.+)$/) { }
13 16 elsif ($line =~ /^Info: (.+)$/) { }
7 9 elsif ($line =~ /^\d+ warnings?, \d+ errors? were found!/) { }
3 6 elsif ($line eq 'No warnings or errors were found.') { }
2 4 elsif ($line eq 'This document has errors that must be fixed before') { }
2 2 elsif ($line eq 'using HTML Tidy to generate a tidied up version.') { }
2 0 elsif ($line =~ /^\s*$/) { }
251 16 9 $type eq 'Info' ? :
126 25 $type eq 'Warning' ? :
288 144 36 if $message and $self->_is_keeper($message)
304 0 11 if (@_ == 0)
309 2 9 if utf8::is_utf8($text)
310 11 0 if (defined $text)
332 41 123 if (@ignore_types)
333 15 26 if grep {$message->type == $_;} @ignore_types
337 13 136 if (@ignore_texts)
338 5 8 if grep {$message->text =~ /$_/;} @ignore_texts