@Test public void importProjectWithPermissionTest() { libraryScreen.importProject(); verify(libraryPlaces).goToImportRepositoryPopUp(); }
public void importProject() { if (userCanCreateProjects()) { libraryPlaces.goToImportRepositoryPopUp(); } }
LibraryScreen { public void importProject() { if (userCanCreateProjects()) { libraryPlaces.goToImportRepositoryPopUp(); } } }
LibraryScreen { public void importProject() { if (userCanCreateProjects()) { libraryPlaces.goToImportRepositoryPopUp(); } } @Inject  LibraryScreen(final View view,
                         final ManagedInstance<DeleteOrganizationalUnitPopUpPresenter> deleteOrganizationalUnitPopUpPresenters,
                         final WorkspaceProjectContext projectContext,
                         final ProjectController projectController,
                         final OrganizationalUnitController organizationalUnitController,
                         final EmptyLibraryScreen emptyLibraryScreen,
                         final PopulatedLibraryScreen populatedLibraryScreen,
                         final OrgUnitsMetricsScreen orgUnitsMetricsScreen,
                         final SettingsScreenPresenter settingsScreenPresenter,
                         final ContributorsListPresenter contributorsListPresenter,
                         final Caller<LibraryService> libraryService,
                         final Caller<OrganizationalUnitService> organizationalUnitService,
                         final LibraryPlaces libraryPlaces,
                         final SpaceContributorsListServiceImpl spaceContributorsListService,
                         final Event<NotificationEvent> notificationEvent,
                         final TranslationService translationService,
                         final Promises promises); }
LibraryScreen { public void importProject() { if (userCanCreateProjects()) { libraryPlaces.goToImportRepositoryPopUp(); } } @Inject  LibraryScreen(final View view,
                         final ManagedInstance<DeleteOrganizationalUnitPopUpPresenter> deleteOrganizationalUnitPopUpPresenters,
                         final WorkspaceProjectContext projectContext,
                         final ProjectController projectController,
                         final OrganizationalUnitController organizationalUnitController,
                         final EmptyLibraryScreen emptyLibraryScreen,
                         final PopulatedLibraryScreen populatedLibraryScreen,
                         final OrgUnitsMetricsScreen orgUnitsMetricsScreen,
                         final SettingsScreenPresenter settingsScreenPresenter,
                         final ContributorsListPresenter contributorsListPresenter,
                         final Caller<LibraryService> libraryService,
                         final Caller<OrganizationalUnitService> organizationalUnitService,
                         final LibraryPlaces libraryPlaces,
                         final SpaceContributorsListServiceImpl spaceContributorsListService,
                         final Event<NotificationEvent> notificationEvent,
                         final TranslationService translationService,
                         final Promises promises); @PostConstruct void init(); void trySamples(); void importProject(); void delete(); void showProjects(); void showContributors(); void showMetrics(); void showSettings(); boolean userCanCreateProjects(); boolean userCanUpdateOrganizationalUnit(); boolean userCanDeleteOrganizationalUnit(); void onNewProject(@Observes NewProjectEvent e); void onRepositoryRemovedEvent(@Observes RepositoryRemovedEvent e); void onProjectCountUpdate(@Observes final ProjectCountUpdate projectCountUpdate); void onSpaceContributorsUpdated(@Observes final SpaceContributorsUpdatedEvent spaceContributorsUpdatedEvent); @OnClose void onClose(); @WorkbenchPartTitle String getTitle(); @WorkbenchPartView View getView(); }
LibraryScreen { public void importProject() { if (userCanCreateProjects()) { libraryPlaces.goToImportRepositoryPopUp(); } } @Inject  LibraryScreen(final View view,
                         final ManagedInstance<DeleteOrganizationalUnitPopUpPresenter> deleteOrganizationalUnitPopUpPresenters,
                         final WorkspaceProjectContext projectContext,
                         final ProjectController projectController,
                         final OrganizationalUnitController organizationalUnitController,
                         final EmptyLibraryScreen emptyLibraryScreen,
                         final PopulatedLibraryScreen populatedLibraryScreen,
                         final OrgUnitsMetricsScreen orgUnitsMetricsScreen,
                         final SettingsScreenPresenter settingsScreenPresenter,
                         final ContributorsListPresenter contributorsListPresenter,
                         final Caller<LibraryService> libraryService,
                         final Caller<OrganizationalUnitService> organizationalUnitService,
                         final LibraryPlaces libraryPlaces,
                         final SpaceContributorsListServiceImpl spaceContributorsListService,
                         final Event<NotificationEvent> notificationEvent,
                         final TranslationService translationService,
                         final Promises promises); @PostConstruct void init(); void trySamples(); void importProject(); void delete(); void showProjects(); void showContributors(); void showMetrics(); void showSettings(); boolean userCanCreateProjects(); boolean userCanUpdateOrganizationalUnit(); boolean userCanDeleteOrganizationalUnit(); void onNewProject(@Observes NewProjectEvent e); void onRepositoryRemovedEvent(@Observes RepositoryRemovedEvent e); void onProjectCountUpdate(@Observes final ProjectCountUpdate projectCountUpdate); void onSpaceContributorsUpdated(@Observes final SpaceContributorsUpdatedEvent spaceContributorsUpdatedEvent); @OnClose void onClose(); @WorkbenchPartTitle String getTitle(); @WorkbenchPartView View getView();  }