Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,14 @@ versionFile << version

repositories {
maven { url "https://sig-repo.synopsys.com/bds-bdio-release" }
mavenLocal()
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note: This PR is dependent/blocked by the release of integrations-bdio 26.0.8. Once that release exists, this PR can be updated to remove this mavenLocal line, and use a non-SNAPSHOT version.
Given the lack of SNAPSHOT availability to the build pipeline, it is likely PR builds will fail for this request until this change is applied.

}

dependencies {
api 'com.synopsys.integration:blackduck-common-api:2022.10.4'
api 'com.synopsys.integration:phone-home-client:5.1.7'

api 'com.synopsys.integration:integration-bdio:26.0.7'
api 'com.synopsys.integration:integration-bdio:26.0.8-SNAPSHOT'
api 'com.blackducksoftware.bdio:bdio2:3.2.5'


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,13 @@ private Pair<List<Project>, List<Component>> createAndLinkComponentsFromGraph(
}
} else {
Component component = componentFromDependency(dependency);
linkComponentDependency.dependency(new com.blackducksoftware.bdio2.model.Dependency().dependsOn(component));
com.blackducksoftware.bdio2.model.Dependency dependencyEntry = new com.blackducksoftware.bdio2.model.Dependency().dependsOn(component);

if (dependency.getScope() != null) {
dependencyEntry = dependencyEntry.scope(dependency.getScope());
}

linkComponentDependency.dependency(dependencyEntry);

if (!existingComponents.containsKey(dependency.getExternalId())) {
addedComponents.add(component);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ void testCreateAndLinkComponents() {
DependencyGraph dependencyGraph = Mockito.mock(DependencyGraph.class);
Set<Dependency> dependencies = new HashSet<>();
ProjectDependency subProjectDependency = new ProjectDependency(subProjectName, subProjectVersion, subProjectExternalId);
Dependency componentDependency = new Dependency(componentExternalId);
Dependency componentDependency = new Dependency(componentExternalId, null);
dependencies.add(subProjectDependency);
dependencies.add(componentDependency);
Mockito.when(dependencyGraph.getDirectDependencies()).thenReturn(dependencies);
Expand Down