Branch Coverage

blib/lib/Net/Radius/Packet.pm
Criterion Covered Total %
branch 57 106 53.7


line true false branch
27 26 1 if defined $dict
28 18 9 if defined $data
54 9 34 unless exists $$self{'VSAttributes'}{$vendor}
57 0 43 if ($rewrite_flag)
60 0 0 if (exists $$attr{$name})
64 0 0 if ($found == 1)
86 135 3 unless $rewrite_flag
88 3 135 if ($rewrite_flag)
93 3 8 if ($attr[$i][0] eq $name)
99 1 2 if ($found > 1) { }
1 1 elsif ($found) { }
111 137 0 if $push
121 12 5 if $attr[$i][0] eq $name
145 3 0 if ($name eq $attr[$i][0] and $value eq $attr[$i][1])
148 3 0 if ($#attr == 0) { }
172 13 554 unless exists $stack[$slot]
173 0 554 unless exists $stack[$slot][0]
183 13 554 unless exists $stack[$slot]
184 0 554 unless exists $stack[$slot][0]
193 4 2 if (not $position > $#attr) { }
206 3 1982 unless $_[0]{'Attributes'}
220 2 0 if $pwdout
221 0 2 unless length $pwdout <= length $pwdin
245 0 2 if ($_[2]) { }
259 2 2 if Digest::MD5::md5(substr($packet, 0, 4) . $prauth . substr($packet, 20) . $secret) eq substr($packet, 4, 16)
266 1024 256 defined $_[0] ? :
328 7 3 defined $$self{'Dict'}->attr_has_val($_[1]) && defined $$self{'Dict'}->val_num(@_[1, 0]) ? :
364 0 1 defined $$self{'Dict'}->vsattr_has_val($vid, $_[1]) && defined $$self{'Dict'}->vsaval_num($vid, @_[1, 0]) ? :
393 0 25 unless (defined $$self{'Dict'}->attr_num($attr))
395 0 0 if $$self{'unknown_entries'}
401 0 25 unless ref $packer{$$self{'Dict'}->attr_type($attr)} eq 'CODE'
416 0 3 unless ref $vsapacker{$$self{'Dict'}->vsattr_type($vid, $attr)} eq 'CODE'
423 0 3 if ($vid == 429) { }
480 15 24 defined $dict->val_has_name($_[1]) && defined $dict->val_name($_[1], $num) ? :
485 13 0 length $_[0] == 4 ? :
488 0 0 length $_[0] == 4 ? :
502 0 0 defined $dict->val_has_name($_[1]) && defined $dict->val_name($_[1], $num) ? :
525 0 16 $dict->vsaval_has_name($_[2], $_[1]) && $dict->vsaval_name($_[2], $_[1], $num) ? :
531 0 0 length $_[0] == 4 ? :
534 0 0 length $_[0] == 4 ? :
548 0 0 $dict->vsaval_has_name($_[2], $_[1]) && $dict->vsaval_name($_[2], $_[1], $num) ? :
564 9 103 if ($type == $Net::Radius::Packet::VSA) { }
581 0 40 if ($vid == 429) { }
591 0 40 if (not defined $dict->vsattr_numtype($vid, $vtype) or ref $vsaunpacker{$dict->vsattr_numtype($vid, $vtype)} ne 'CODE')
595 0 0 defined $dict->vsattr_numtype($vid, $vtype) ? :
598 0 0 unless $unkvprinted{"$vid/$vtype"}
608 0 40 if (defined $tag) { }
610 0 0 unless defined $val
626 0 103 if (not defined $dict->attr_numtype($type) or ref $unpacker{$dict->attr_numtype($type)} ne 'CODE')
629 0 0 defined $dict->attr_numtype($type) ? :
631 0 0 unless $unkgprinted{$type}
639 0 103 if (defined $tag) { }
640 0 0 unless (defined $val)