diff --git a/xray/utils/resultwriter_test.go b/xray/utils/resultwriter_test.go index 9acc6e28b..a67dfe86c 100644 --- a/xray/utils/resultwriter_test.go +++ b/xray/utils/resultwriter_test.go @@ -171,6 +171,12 @@ func TestGetXrayIssueLocationIfValidExists(t *testing.T) { run: CreateRunWithDummyResults().WithInvocations([]*sarif.Invocation{invocation}), expectedOutput: sarif.NewLocation().WithPhysicalLocation(sarif.NewPhysicalLocation().WithArtifactLocation(sarif.NewArtifactLocation().WithUri("file://" + filepath.Join(testDir, "go.mod")))), }, + { + name: "One descriptor information - no invocation", + tech: coreutils.Go, + run: CreateRunWithDummyResults(), + expectedOutput: sarif.NewLocation().WithPhysicalLocation(sarif.NewPhysicalLocation().WithArtifactLocation(sarif.NewArtifactLocation().WithUri("file://go.mod"))), + }, { name: "Multiple descriptor information", tech: coreutils.Gradle,