ProcessDefinitionListPresenter extends AbstractMultiGridPresenter<ProcessSummary, ProcessDefinitionListPresenter.ProcessDefinitionListView> { @Override protected void selectSummaryItem(ProcessSummary processSummary) { setupDetailBreadcrumb(constants.ProcessDefinitionBreadcrumb(processSummary.getName())); placeManager.goTo(PerspectiveIds.PROCESS_DEFINITION_DETAILS_SCREEN); fireProcessDefSelectionEvent(processSummary); } ProcessDefinitionListPresenter(); @Inject void setAuthorizationManager(final AuthorizationManager authorizationManager); @Inject void setProcessDefinitionListBasicFiltersPresenter(final ProcessDefinitionListBasicFiltersPresenter processDefinitionListBasicFiltersPresenter); @Override void setupActiveSearchFilters(); @Override boolean existActiveSearchFilters(); @Override void createListBreadcrumb(); void setupDetailBreadcrumb(String detailLabel); void openGenericForm(final String processDefId,
                                final String deploymentId,
                                final String processDefName,
                                final boolean isDynamic); @Inject void setFilterSettingsManager(final ProcessDefinitionListFilterSettingsManager filterSettingsManager); @WorkbenchMenu void getMenus(final Consumer<Menus> menusConsumer); void refreshNewProcessInstance(@Observes NewProcessInstanceEvent newProcessInstance); void refreshNewCaseInstance(@Observes NewCaseInstanceEvent newCaseInstance); Predicate<ProcessSummary> getViewProcessInstanceActionCondition(); Predicate<ProcessSummary> getStartCondition(); void viewProcessInstances(String processDefId); boolean isUserAuthorizedForPerspective(final String perspectiveId); @Inject void setProcessRuntimeDataService(final Caller<ProcessRuntimeDataService> processRuntimeDataService);  }
@Test public void testProcessDefNameDefinitionPropagation() { final ProcessSummary processSummary = new ProcessSummary(); processSummary.setProcessDefId("testProcessDefId"); processSummary.setDeploymentId("testDeploymentId"); processSummary.setProcessDefName("testProcessDefName"); processSummary.setDynamic(false); presenter.selectSummaryItem(processSummary); verify(processDefSelectionEvent).fire(any(ProcessDefSelectionEvent.class)); ArgumentCaptor<ProcessDefSelectionEvent> argument = ArgumentCaptor.forClass(ProcessDefSelectionEvent.class); verify(processDefSelectionEvent).fire(argument.capture()); final ProcessDefSelectionEvent event = argument.getValue(); assertEquals(processSummary.getProcessDefName(), event.getProcessDefName()); assertEquals(processSummary.getDeploymentId(), event.getDeploymentId()); assertEquals(processSummary.getProcessDefId(), event.getProcessId()); assertEquals(processSummary.isDynamic(), event.isDynamic()); verify(breadcrumbs).addBreadCrumb(eq(PERSPECTIVE_ID), eq(Constants.INSTANCE.ProcessDefinitionBreadcrumb((processSummary.getName()))), eq(Commands.DO_NOTHING)); }