Skip to content

Commit

Permalink
Missing context new status
Browse files Browse the repository at this point in the history
  • Loading branch information
barv-jfrog committed Aug 21, 2024
1 parent fbc3f1b commit 64ce36f
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions utils/resultstable_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -720,6 +720,20 @@ func TestGetApplicableCveValue(t *testing.T) {
{Id: "testCve2", Applicability: &formats.Applicability{Status: jasutils.NotApplicable.String()}},
},
},
{
name: "new scan statuses - undetermined wins not covered",
scanResults: &ExtendedScanResults{
ApplicabilityScanResults: []*sarif.Run{
sarifutils.CreateRunWithDummyResultAndRuleProperties("applicability", "not_covered", sarifutils.CreateDummyPassingResult("applic_testCve1")),
sarifutils.CreateRunWithDummyResultAndRuleProperties("applicability", "undetermined", sarifutils.CreateDummyPassingResult("applic_testCve2")),
},
EntitledForJas: true},
cves: []services.Cve{{Id: "testCve1"}, {Id: "testCve2"}},
expectedResult: jasutils.ApplicabilityUndetermined,
expectedCves: []formats.CveRow{{Id: "testCve1", Applicability: &formats.Applicability{Status: jasutils.NotCovered.String()}},
{Id: "testCve2", Applicability: &formats.Applicability{Status: jasutils.ApplicabilityUndetermined.String()}},
},
},
{
name: "new scan statuses - missing context wins applicable",
scanResults: &ExtendedScanResults{
Expand Down

0 comments on commit 64ce36f

Please sign in to comment.