### Question:
DecisionNavigatorPresenter { public void refresh() { if (dmnDiagramsSession.isSessionStatePresent()) { refreshTreeView(); refreshComponentsView(); } } @Inject  DecisionNavigatorPresenter(final View view,
                                      final DecisionNavigatorTreePresenter treePresenter,
                                      final DecisionComponents decisionComponents,
                                      final DecisionNavigatorObserver decisionNavigatorObserver,
                                      final TranslationService translationService,
                                      final EditorContextProvider context,
                                      final DecisionNavigatorItemsProvider navigatorItemsProvider,
                                      final DMNDiagramsSession dmnDiagramsSession); @WorkbenchPartView View getView(); @WorkbenchPartTitle String getTitle(); @DefaultPosition Position getDefaultPosition(); void onRefreshDecisionComponents(final @Observes RefreshDecisionComponents events); void onElementAdded(final @Observes CanvasElementAddedEvent event); DecisionNavigatorTreePresenter getTreePresenter(); void removeAllElements(); void refresh(); void refreshTreeView(); void enableRefreshHandlers(); void disableRefreshHandlers(); void clearSelections(); static final String IDENTIFIER; }### Answer:
@Test public void testRefresh() { doReturn(true).when(dmnDiagramsSession).isSessionStatePresent(); presenter.refresh(); verify(presenter).refreshTreeView(); verify(presenter).refreshComponentsView(); }