@Test public void testAddAllPackagesToWhiteList() { final DependenciesPresenter parentPresenter = mock(DependenciesPresenter.class); final Set<String> packages = new HashSet<>(Arrays.asList("foo", "bar")); final EnhancedDependency enhancedDependency = new NormalEnhancedDependency(mock(Dependency.class), packages); dependenciesItemPresenter.parentPresenter = parentPresenter; dependenciesItemPresenter.enhancedDependency = enhancedDependency; dependenciesItemPresenter.addAllPackagesToWhiteList(); verify(parentPresenter).addAllToWhiteList(eq(packages)); }
public void addAllPackagesToWhiteList() { parentPresenter.addAllToWhiteList(enhancedDependency.getPackages()); }
DependenciesItemPresenter { public void addAllPackagesToWhiteList() { parentPresenter.addAllToWhiteList(enhancedDependency.getPackages()); } }
DependenciesItemPresenter { public void addAllPackagesToWhiteList() { parentPresenter.addAllToWhiteList(enhancedDependency.getPackages()); } @Inject  DependenciesItemPresenter(final View view); }
DependenciesItemPresenter { public void addAllPackagesToWhiteList() { parentPresenter.addAllToWhiteList(enhancedDependency.getPackages()); } @Inject  DependenciesItemPresenter(final View view); DependenciesItemPresenter setup(final EnhancedDependency enhancedDependency,
                                           final WhiteList whiteList,
                                           final DependenciesPresenter dependenciesPresenter); void onGroupIdChange(final String groupId); void onArtifactIdChange(final String artifactId); void onVersionChange(final String version); void addAllPackagesToWhiteList(); void removeAllPackagesFromWhiteList(); void remove(); View getView(); }
DependenciesItemPresenter { public void addAllPackagesToWhiteList() { parentPresenter.addAllToWhiteList(enhancedDependency.getPackages()); } @Inject  DependenciesItemPresenter(final View view); DependenciesItemPresenter setup(final EnhancedDependency enhancedDependency,
                                           final WhiteList whiteList,
                                           final DependenciesPresenter dependenciesPresenter); void onGroupIdChange(final String groupId); void onArtifactIdChange(final String artifactId); void onVersionChange(final String version); void addAllPackagesToWhiteList(); void removeAllPackagesFromWhiteList(); void remove(); View getView();  }