Condition Coverage

blib/lib/WWW/Mechanize/Firefox.pm
Criterion Covered Total %
condition 0 250 0.0


and 3 conditions

line !l l&&!r l&&r condition
1050 0 0 0 $self->{'custom_header_observer'} and @headers
1191 0 0 0 @args <= 2 and ref $args[0] eq 'MozRepl::RemoteObject::Instance'
1382 0 0 0 ref $events and ref $events eq 'CODE'
1480 0 0 0 $scheme and $scheme =~ /^https?/
0 0 0 $scheme and $scheme =~ /^(file|data|about)\b/
2083 0 0 0 defined $self->ct && $self->ct eq 'text/html'
2315 0 0 0 $single and exists $opts{'n'}
2619 0 0 0 defined wantarray and not wantarray
2645 0 0 0 not $zero_allowed and @res == 0
2650 0 0 0 not $two_allowed and @res > 1
2810 0 0 0 @res and $options{'return_first'}
0 0 0 @res and $options{'return_first'} and grep {$_->{'resultSize'};} @res
2815 0 0 0 $options{'frames'} and not $options{'node'}
2960 0 0 0 ref $name and &blessed($name)
0 0 0 ref $name and &blessed($name) and $name->can('__click')
3506 0 0 0 ref $name and &blessed($name)
0 0 0 ref $name and &blessed($name) and $name->can('__click')
3911 0 0 0 $v = $self->is_visible($node) and !$timeout_after || time < $timeout_after
3921 0 0 0 $node and time >= $timeout_after
3985 0 0 0 not ref $spec || $spec =~ /\D/ and $spec == 1

or 2 conditions

line l !l condition
232 0 0 $args{'events'} ||= ['DOMContentLoaded', 'load', 'pageshow', 'error', 'abort', 'stop']
237 0 0 $args{'on_event'} ||= undef
238 0 0 $args{'pre_value'} ||= ['focus']
239 0 0 $args{'post_value'} ||= ['change', 'blur']
241 0 0 $args{'frames'} ||= 1
251 0 0 $args{'response'} ||= undef
252 0 0 $args{'current_form'} ||= undef
254 0 0 $args{'event_log'} ||= []
517 0 0 $env ||= {}
913 0 0 $options{'charset'} ||= 'utf-8'
914 0 0 $options{'headers'} ||= {}
915 0 0 $options{'headers'}{'Content-Type'} ||= 'application/x-www-form-urlencoded'
1253 0 0 $element->{'busy'} || 0
1555 0 0 $bypass_cache ||= 0
1704 0 0 $options{'format'} ||= 'html'
1707 0 0 delete $options{'format'} || 'html'
2318 0 0 delete $opts{'n'} || 1
2419 0 0 $opts{'n'} || ''
2662 0 0 $self->{'XpathResultTypes'} ||= {'ANY_TYPE', $self->repl->constant('XPathResult.ANY_TYPE'), 'NUMBER_TYPE', $self->repl->constant('XPathResult.NUMBER_TYPE'), 'STRING_TYPE', $self->repl->constant('XPathResult.STRING_TYPE'), 'BOOLEAN_TYPE', $self->repl->constant('XPathResult.BOOLEAN_TYPE'), 'UNORDERED_NODE_ITERATOR_TYPE', $self->repl->constant('XPathResult.UNORDERED_NODE_ITERATOR_TYPE'), 'ORDERED_NODE_ITERATOR_TYPE', $self->repl->constant('XPathResult.ORDERED_NODE_ITERATOR_TYPE'), 'UNORDERED_NODE_SNAPSHOT_TYPE', $self->repl->constant('XPathResult.UNORDERED_NODE_SNAPSHOT_TYPE'), 'ORDERED_NODE_SNAPSHOT_TYPE', $self->repl->constant('XPathResult.ORDERED_NODE_SNAPSHOT_TYPE'), 'ANY_UNORDERED_TYPE', $self->repl->constant('XPathResult.ANY_UNORDERED_NODE_TYPE'), 'FIRST_ORDERED_NODE_TYPE', $self->repl->constant('XPathResult.FIRST_ORDERED_NODE_TYPE')}
2711 0 0 ref $query || ''
2846 0 0 ref $query || ''
2873 0 0 ref $query || ''
2970 0 0 $options{'name'} || ''
3440 0 0 'HASH' eq ref $value or ''
0 0 'ARRAY' eq ref $value or ''
3658 0 0 delete $options{'fields'} || {}
3899 0 0 delete $options{'sleep'} || 0.3
3900 0 0 delete $options{'timeout'} || 0
4064 0 0 $rect ||= {}
4065 0 0 $target_rect ||= {}

or 3 conditions

line l !l&&r !l&&!r condition
519 0 0 0 $doc ||= $self->document
550 0 0 0 $window ||= $self->tab->{'linkedBrowser'}{'contentWindow'}
1029 0 0 0 $self->{'custom_header_observer'} ||= $self->_custom_header_observer
1075 0 0 0 $options{'tab'} ||= $self->tab
1076 0 0 0 $options{'window'} ||= $self->application->getMostRecentWindow
1077 0 0 0 $options{'events'} ||= $self->events
1195 0 0 0 $_->[1] ||= $self->events
1354 0 0 0 $STATE_STOP == $flags or ($flags & ($STATE_STOP | $STATE_IS_DOCUMENT)) == ($STATE_STOP | $STATE_IS_DOCUMENT)
1359 0 0 0 $self->{'response'} ||= $request
1588 0 0 0 $synchronize ||= @_ != 2
1612 0 0 0 $synchronize ||= @_ != 2
1706 0 0 0 delete $options{'document'} || $self->document
1765 0 0 0 $d ||= $self->document
2052 0 0 0 $base ||= $self->uri
2186 0 0 0 $self->response('headers', 0)->message || sprintf('Got status code %d', $self->status)
2314 0 0 0 delete $opts{'one'} || $single
2335 0 0 0 $lefthand{$lvalue} || '@' . $lvalue
2610 0 0 0 $single || $first || $maybe || $any
2613 0 0 0 $single || $first
2614 0 0 0 $single || $maybe
2618 0 0 0 exists $options{'all'} or $return_first_element
2637 0 0 0 $_->{'resultType'} == $self->{'XpathResultTypes'}{'ORDERED_NODE_SNAPSHOT_TYPE'} || $_->{'resultType'} == $self->{'XpathResultTypes'}{'UNORDERED_NODE_SNAPSHOT_TYPE'} || $_->{'resultType'} == $self->{'XpathResultTypes'}{'ORDERED_NODE_ITERATOR_TYPE'} || $_->{'resultType'} == $self->{'XpathResultTypes'}{'UNORDERED_NODE_ITERATOR_TYPE'}
2646 0 0 0 $options{'user_info'} ||= $query
2651 0 0 0 $options{'user_info'} ||= $query
2716 0 0 0 $options{'document'} ||= $options{'node'}{'ownerDocument'}
2719 0 0 0 $options{'document'} ||= $self->document
2724 0 0 0 $options{'type'} ||= $self->{'XpathResult'}{'ANY_TYPE'}
2726 0 0 0 $options{'user_info'} ||= join(' or ', map({"'${_}'";} @$query))
2800 0 0 0 $options{'node'} || $doc
2845 0 0 0 $options{'user_info'} ||= "CSS selector '${query}'"
2877 0 0 0 $options{'user_info'} ||= 'id ' . join(' or ', map({"'${_}'";} @$query)) . ' found'
3069 0 0 0 $node ||= $self->xpath($xpath, 'node', $self->current_form, 'single', 1, 'user_message', $user_message)
3348 0 0 0 delete $options{'pre'} || $self->{'pre_value'}
3349 0 0 0 delete $options{'post'} || $self->{'post_value'}
3586 0 0 0 $dom_form ||= $self->current_form
3808 0 0 0 $options{'window'} ||= $self->tab->{'linkedBrowser'}{'contentWindow'}
3911 0 0 0 !$timeout_after || time < $timeout_after
3941 0 0 0 $rename{$meth} || $meth
3981 0 0 0 $spec ||= $self->{'frames'}
3983 0 0 0 $document ||= $self->document
3985 0 0 0 ref $spec || $spec =~ /\D/
4063 0 0 0 $tab ||= $self->tab

xor 4 conditions

line l&&r l&&!r !l&&r !l&&!r condition
3547 0 0 0 0 $set xor $is_set