Branch Coverage

blib/lib/CVSS/v4.pm
Criterion Covered Total %
branch 61 80 76.2


line true false branch
55 291 865 if $self->M("AV") eq "N" and $self->M("PR") eq "N" and $self->M("UI") eq "N"
57 1506 369 if $self->M('AV') eq 'N' || $self->M('PR') eq 'N' || $self->M('UI') eq 'N' and not $self->M('AV') eq 'N' && $self->M('PR') eq 'N' && $self->M('UI') eq 'N' and not $self->M("AV") eq "P"
62 243 1797 if $self->M("AV") eq "P" or not $self->M('AV') eq 'N' || $self->M('PR') eq 'N' || $self->M('UI') eq 'N'
73 947 1093 if $self->M("AC") eq "L" and $self->M("AT") eq "N"
74 1093 947 unless $self->M("AC") eq "L" and $self->M("AT") eq "N"
84 471 1569 if $self->M("VC") eq "H" and $self->M("VI") eq "H"
86 500 739 if not $self->M('VC') eq 'H' && $self->M('VI') eq 'H' and $self->M('VC') eq 'H' || $self->M('VI') eq 'H' || $self->M('VA') eq 'H'
90 739 500 unless $self->M("VC") eq "H" or $self->M("VI") eq "H" or $self->M("VA") eq "H"
101 0 2040 if $self->M("MSI") eq "S" or $self->M("MSA") eq "S"
103 177 1366 if not $self->M('MSI') eq 'S' || $self->M('MSA') eq 'S' and $self->M('SC') eq 'H' || $self->M('SI') eq 'H' || $self->M('SA') eq 'H'
107 1366 177 unless ($self->M("MSI") eq "S" or $self->M("MSA") eq "S") or ($self->M("SC") eq "H" or $self->M("SI") eq "H" or $self->M("SA") eq "H")
120 2040 0 if $self->M("E") eq "A"
121 0 2040 if $self->M("E") eq "P"
122 0 2040 if $self->M("E") eq "U"
132 500 739 if $self->M("CR") eq "H" and $self->M("VC") eq "H" or $self->M("IR") eq "H" and $self->M("VI") eq "H" or $self->M("AR") eq "H" and $self->M("VA") eq "H"
137 739 194 unless $self->M("CR") eq "H" and $self->M("VC") eq "H" or $self->M("IR") eq "H" and $self->M("VI") eq "H" or $self->M("AR") eq "H" and $self->M("VA") eq "H"
169 2040 0 wantarray ? :
189 6120 161542 if $metric eq "E" and $value eq "X"
195 9849 151693 if $metric eq "CR" and $value eq "X"
196 8247 143446 if $metric eq "IR" and $value eq "X"
197 7635 135811 if $metric eq "AR" and $value eq "X"
207 2054 0 if (%{$self->metrics;})
209 0 22594 unless $self->metrics->{$_}
263 14 40 if ($self->M("VC") eq "N" and $self->M("VI") eq "N" and $self->M("VA") eq "N" and $self->M("SC") eq "N" and $self->M("SI") eq "N" and $self->M("SA") eq "N")
289 0 2040 if ($eq3 == 1 and $eq6 == 1) { }
0 2040 elsif ($eq3 == 0 and $eq6 == 1) { }
830 1210 elsif ($eq3 == 1 and $eq6 == 0) { }
471 739 elsif ($eq3 == 0 and $eq6 == 0) { }
315 471 1569 if ($eq3 == 0 and $eq6 == 0) { }
423 3729 32917 if $_ < 0
479 1797 243 if (not isNaN($available_distance_eq1) and $available_distance_eq1 >= 0)
485 947 1093 if (not isNaN($available_distance_eq2) and $available_distance_eq2 >= 0)
491 1301 739 if (not isNaN($available_distance_eq3eq6) and $available_distance_eq3eq6 >= 0)
497 674 1366 if (not isNaN($available_distance_eq4) and $available_distance_eq4 >= 0)
503 2040 0 if (not isNaN($available_distance_eq5) and $available_distance_eq5 >= 0)
512 0 2040 if ($n_existing_lower == 0) { }
564 0 0 unless $self->base_score
591 0 0 if ($self->metric_group_is_set("threat"))
599 0 0 if ($self->metric_group_is_set("environmental"))
622 0 0 if ($self->metric_group_is_set("supplemental"))