Branch Coverage

blib/lib/Data/Radius/Encode.pm
Criterion Covered Total %
branch 26 48 54.1


line true false branch
76 5 8 $attr && $attr->{'vendor'} ? :
77 2 11 if (length $value > $max_size)
86 0 0 $attr && $attr->{'vendor'} ? :
88 0 0 if (defined $tag)
89 0 0 if ($tag > 31)
95 0 0 if (length $value > $max_size)
100 0 0 if (defined $tag)
115 0 0 if (defined $tag)
116 0 0 if ($tag > 31)
131 0 0 unless $expanded_value
133 0 0 unless defined $bin_value
140 1 1 unless ($value =~ /^0x(?:[0-9A-Fa-f]{2})+$/)
152 1 1 if ($ip =~ /^\d+\.\d+.\d+.\d+$/)
161 4 0 if (($attr->{'vendor'} // '') eq 'Cisco')
165 2 2 if ($attr->{'id'} == 1 and $attr->{'name'} ne 'Cisco-AVPair')
170 2 2 if (length $value > 247)
185 0 3 unless ($attr)
193 0 3 if (($attr->{'parent'} // '') ne $parent->{'name'})
200 1 2 if (is_enum_type($attr->{'type'})) { }
219 1 43 unless (defined $value)
224 0 43 $attr->{'has_tag'} ? :
227 16 27 if ($limits)
229 1 15 unless ($value =~ /^-?\d+$/)
235 8 7 if ($value < $min or $value > $max)