Condition Coverage

blib/lib/Text/HTML/CollapseWhitespace.pm
Criterion Covered Total %
condition 34 43 79.0


and 3 conditions

line !l l&&!r l&&r condition
70 15 8 624 !$prevText || $prevText->data =~ / $/u and not $keepLeadingWs
23 255 369 !$prevText || $prevText->data =~ / $/u and not $keepLeadingWs and substr($text, 0, 1) eq " "
150 333 853 673 $prev and $prev->parentNode->isEqual($current)

or 2 conditions

line l !l condition
51 167 0 $options{'isBlock'} // \&Text::HTML::Turndown::Node::_isBlock
52 167 0 $options{'isVoid'} // \&Text::HTML::Turndown::Node::_isVoid

or 3 conditions

line l !l&&r !l&&!r condition
55 5 162 0 $options{'isPre'} || sub ($node) { return uc $node->nodeName eq 'PRE'; }
58 0 0 167 not $element->firstChild or &$isPre($element)
67 647 0 1575 $node->nodeType == 3 or $node->nodeType == 4
70 616 16 15 !$prevText || $prevText->data =~ / $/u
85 1258 6 143 &$isBlock($node) or uc $node->nodeName eq "BR"
14 5 124 &$isVoid($node) or &$isPre($node)
128 383 147 0 $node->nextSibling || $node->parentNode
150 673 25 1161 $prev and $prev->parentNode->isEqual($current) or &$isPre($current)
151 280 418 0 $current->nextSibling || $current->parentNode
154 886 275 0 $current->firstChild || $current->nextSibling || $current->parentNode