Branch Coverage

lib/Net/ISC/DHCPd/Config/Role.pm
Criterion Covered Total %
branch 19 88 21.5


line true false branch
74 0 0 if $obj == $self->root
181 0 2 if (my $parent = $self->parent)
185 1 1 if ($self->fh)
191 0 1 if ($file->is_relative and not -e $file)
231 0 2 if $$args{'parse'}
238 0 3 if (ref $list eq 'ARRAY' and $meta->has_method($method))
266 2 0 unless (defined $fh)
273 0 2 if (defined $$linebuf[0]) { }
277 0 2 unless defined($line = <$fh>)
284 0 2 if ($line =~ /^\s*\#\s*(.*)/)
290 0 2 if ($line =~ s/([;\{\}])([^;\n\r])/$1\n$2/g)
297 0 2 if ($line =~ /^(?:\s*|\s*\{\s*)$/) { }
0 2 elsif ($line =~ /^\s*\}\s*$/) { }
301 0 0 if $self->root == $self
307 0 2 if ($lines) { }
317 4 2 unless my(@c) = $lines =~ /$regex/
328 0 0 if $obj->can('slurp')
331 0 0 if @_ = $obj->children
342 0 0 unless ($lines =~ /;/)
346 0 0 if (warnings::enabled('net_isc_dhcpd_config_parse'))
355 0 0 $n ? :
375 0 0 if (defined $$linebuf[0]) { }
378 0 0 unless defined($line = <$fh>)
384 0 0 if ($self->can('slurp'))
386 0 0 if ($action eq 'next') { }
0 0 elsif ($action eq 'last') { }
0 0 elsif ($action eq 'backtrack') { }
435 42 203 if $name =~ /s$/
440 202 0 unless ($meta->find_method_by_name($attr))
446 0 0 if @_
459 0 0 if ref $child eq 'HASH'
469 0 0 wantarray ? :
475 0 0 @_ == 1 ? :
478 0 0 if (ref $child eq 'HASH')
490 0 0 if (ref $query ne 'HASH')
496 0 0 if ($class ne ref $child)
500 0 0 unless $child->$key eq $$query{$key}
511 0 0 unless my $query = shift()
518 0 0 if ($class ne ref $$children[$i])
522 0 0 unless $$children[$i]->$key eq $$query{$key}
550 0 0 unless ($class =~ /::/)
558 0 0 if (ref $child eq $class)
562 0 0 if ($child->_children)
587 0 0 if ($self->parent and not $self->can('generate_with_include'))