use of org.kie.workbench.common.services.shared.dependencies.TransitiveEnhancedDependency in project kie-wb-common by kiegroup.
the class DependenciesItemPresenterTest method testSetupTransitive.
@Test
public void testSetupTransitive() {
dependenciesItemPresenter.setup(new TransitiveEnhancedDependency(mock(Dependency.class), emptySet()), new WhiteList(), mock(DependenciesPresenter.class));
verify(view).init(any());
verify(view).setGroupId(any());
verify(view).setArtifactId(any());
verify(view).setVersion(any());
verify(view).setPackagesWhiteListedState(any());
verify(view).setTransitiveDependency(eq(true));
}
use of org.kie.workbench.common.services.shared.dependencies.TransitiveEnhancedDependency in project kie-wb-common by kiegroup.
the class DependenciesItemPresenter method setup.
public DependenciesItemPresenter setup(final EnhancedDependency enhancedDependency, final WhiteList whiteList, final DependenciesPresenter dependenciesPresenter) {
this.enhancedDependency = enhancedDependency;
this.parentPresenter = dependenciesPresenter;
final Dependency dependency = enhancedDependency.getDependency();
view.init(this);
view.setGroupId(dependency.getGroupId());
view.setArtifactId(dependency.getArtifactId());
view.setVersion(dependency.getVersion());
view.setPackagesWhiteListedState(WhiteListedPackagesState.from(whiteList, enhancedDependency.getPackages()));
view.setTransitiveDependency(enhancedDependency instanceof TransitiveEnhancedDependency);
return this;
}
Aggregations