]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-23098 Parse dependencies in the FOSSA report
authorJulien HENRY <julien.henry@sonarsource.com>
Fri, 11 Oct 2024 09:25:36 +0000 (11:25 +0200)
committersonartech <sonartech@sonarsource.com>
Mon, 21 Oct 2024 20:03:59 +0000 (20:03 +0000)
sonar-scanner-engine/src/testFixtures/java/org/sonar/scanner/mediumtest/AnalysisResult.java

index 5751aada0f874ab8a3266e1e0f98c2820c0bb98c..584bf3dbfd7840cec92d4e0baea0cd363f47fa91 100644 (file)
@@ -203,6 +203,10 @@ public class AnalysisResult implements AnalysisObserver {
     return readFromReport(ScannerReportReader::readCves);
   }
 
+  public List<ScannerReport.Dependency> dependencies() {
+    return readFromReport(ScannerReportReader::readDependencies);
+  }
+
   @NotNull
   private <G> List<G> readFromReport(InputComponent component, BiFunction<ScannerReportReader, Integer, CloseableIterator<G>> readerMethod) {
     int ref = ((DefaultInputComponent) component).scannerId();