Branch Coverage

blib/lib/Data/Radius/Packet.pm
Criterion Covered Total %
branch 62 94 65.9


line true false branch
77 0 4 if ($h{'secret'})
80 0 4 unless defined $self->secret
85 0 4 if ($self->is_reply($type) and not $h{'authenticator'})
91 3 1 if ($type == 1)
100 1 10 if ($av->{'Name'} eq 'Message-Authenticator' and not $av->{'Value'})
107 0 10 if ($@)
109 0 0 if $h{'RaiseError'}
110 0 0 if $h{'PrintError'}
112 10 0 if $bin
125 3 1 if ($with_msg_auth)
131 2 1 if ($type == 1) { }
1 0 elsif ($self->is_request($type)) { }
160 1 3 unless ($authenticator)
162 1 0 $self->is_request($type) ? :
171 0 4 unless $authenticator
195 2 11 if ($av->{'Id'}) { }
11 0 elsif (defined $av->{'Name'}) { }
196 0 2 unless $av->{'Type'}
208 0 11 unless $dict
211 2 9 if ($av->{'Name'} =~ /^([\w-]+):(\d+)$/)
216 0 11 unless $attr = $dict->attribute($av->{'Name'})
222 3 10 if (defined $av->{'Tag'})
224 0 3 if $av->{'Tag'} < 1 or $av->{'Tag'} > 31
228 0 13 unless defined $value
230 3 10 if ($attr->{'id'} == 2 and not $vendor_id)
235 2 11 if ($attr->{'type'} ne 'tlv' and is_enum_type($attr->{'type'}) and $dict)
242 0 13 unless my $len_encoded = length $encoded
245 10 3 unless ($vendor_id)
253 1 2 if ($vendor_id == 24757) { }
275 2 1 if ($type == 1) { }
280 1 0 if ($self->is_request($type)) { }
285 0 0 unless ($orig_auth)
298 0 1 if ($auth ne $expected_auth)
317 1 9 if ($attr_id == 26) { }
321 0 1 if ($vendor_id == 24757)
325 0 0 if $wimax_cont
329 1 0 if ($dict)
337 9 0 if ($dict)
344 2 8 if ($attr_id == 80 and not $vendor)
345 0 2 if $attr_len != 18
354 0 10 unless ($attr)
367 2 8 if (is_enum_type($attr->{'type'}))
373 2 6 if ($type == 1 and $attr->{'id'} == 2 and not $attr->{'vendor'})
386 2 1 if ($msg_auth)
389 0 2 if ($self->is_reply($type)) { }
1 1 elsif ($type == 1) { }
410 0 2 if ($msg_auth ne $exp_msg_auth)