@Test public void testCopyrightsIsParsedCorrectly() throws URISyntaxException { configureAnalyzer("dependencyWithMultipleCopyrights.csv", ","); Set<Artifact> artifacts = analyzer.yield().getArtifacts(); assertThat(artifacts).hasSize(2); assertThat(artifacts.stream().map(artifact1 -> artifact1.askForGet(CopyrightStatement.class).get()) .anyMatch(copyrightStatement -> copyrightStatement.equals(new CopyrightStatement("Copyright 2005-2016 The Apache Software Foundation") .mergeWith(new CopyrightStatement("Copyright 2020 Fake Company")) .mergeWith(new CopyrightStatement("Copyright 2020 Fake the 2nd")).get()))).isTrue(); }
@Override public WorkflowStepResult yield() { Collection<Artifact> artifacts = new CSVArtifactMapper( componentInfoFile.toPath(), context.getToolConfiguration().getEncoding(), rowDelimiter, baseDir).createArtifactsList(); return new WorkflowStepResult(artifacts, true); }
CsvAnalyzer extends ManualAnalyzer { @Override public WorkflowStepResult yield() { Collection<Artifact> artifacts = new CSVArtifactMapper( componentInfoFile.toPath(), context.getToolConfiguration().getEncoding(), rowDelimiter, baseDir).createArtifactsList(); return new WorkflowStepResult(artifacts, true); } }
CsvAnalyzer extends ManualAnalyzer { @Override public WorkflowStepResult yield() { Collection<Artifact> artifacts = new CSVArtifactMapper( componentInfoFile.toPath(), context.getToolConfiguration().getEncoding(), rowDelimiter, baseDir).createArtifactsList(); return new WorkflowStepResult(artifacts, true); } CsvAnalyzer(); }
CsvAnalyzer extends ManualAnalyzer { @Override public WorkflowStepResult yield() { Collection<Artifact> artifacts = new CSVArtifactMapper( componentInfoFile.toPath(), context.getToolConfiguration().getEncoding(), rowDelimiter, baseDir).createArtifactsList(); return new WorkflowStepResult(artifacts, true); } CsvAnalyzer(); @Override WorkflowStepResult yield(); @Override void configure(Map<String, String> configMap); @Override String getName(); }
CsvAnalyzer extends ManualAnalyzer { @Override public WorkflowStepResult yield() { Collection<Artifact> artifacts = new CSVArtifactMapper( componentInfoFile.toPath(), context.getToolConfiguration().getEncoding(), rowDelimiter, baseDir).createArtifactsList(); return new WorkflowStepResult(artifacts, true); } CsvAnalyzer(); @Override WorkflowStepResult yield(); @Override void configure(Map<String, String> configMap); @Override String getName();  }