Condition Coverage

blib/lib/XML/API.pm
Criterion Covered Total %
condition 28 67 41.7


and 3 conditions

line !l l&&!r l&&r condition
305 0 29 6 defined $arg and $arg =~ /^-[^0-9\.]+/o
432 2 2 0 ref $item and $item->isa('XML::API')
548 0 0 1 ref $val and ref $val eq 'ARRAY'
554 1 0 0 ref $arg2 and ref $arg2 eq 'ARRAY'
573 0 1 0 ref $c and ref $c eq 'ARRAY'
0 0 1 ref $c and ref $c eq 'HASH'
634 0 0 2 defined $_ and $_ ne ''
661 0 0 0 defined $_ and $_ ne ''
711 3 1 1 $self->{'has_root_element'} and not $self->_lang

or 2 conditions

line l !l condition
63 50 31 shift() || ''
64 75 6 shift() || ''

or 3 conditions

line l !l&&r !l&&!r condition
12 0 64 0 ref $proto || $proto
155 0 2 0 ref $proto || $proto
226 0 16 0 ref $proto || $proto
252 0 0 15 $self->{'encoding'} || $ENCODING || $DEFAULT_ENCODING
281 58 0 0 shift() || croak('_open($element,...)')
446 46 0 0 shift() || croak('_close($element)')
477 3 0 0 shift() || croak('_element($element)')
690 0 0 2 not $attrs or ref $attrs ne 'HASH'
708 5 0 0 shift() || croak('usage: set_lang($lang)')
792 0 0 0 not defined $id or $id eq ''
832 17 0 6 ref $self eq 'XML::API' or $self->{'has_root_element'}
864 2 0 0 ref $self eq 'XML::API' or $self->{'has_root_element'}