@Test public void testOnRemoveClick() { final HTMLElement element = mock(HTMLElement.class); final DecisionNavigatorItem item = mock(DecisionNavigatorItem.class); final ClickEvent event = mock(ClickEvent.class); final org.jboss.errai.common.client.dom.DOMTokenList tokenList = mock(org.jboss.errai.common.client.dom.DOMTokenList.class); doReturn(element).when(treeItem).getElement(); doReturn(item).when(treeItem).getItem(); when(element.getClassList()).thenReturn(tokenList); treeItem.onRemoveClick(event); verify(item).onRemove(); }
@Override public HTMLElement getElement() { return view; }
DecisionNavigatorTreeView implements DecisionNavigatorTreePresenter.View { @Override public HTMLElement getElement() { return view; } }
DecisionNavigatorTreeView implements DecisionNavigatorTreePresenter.View { @Override public HTMLElement getElement() { return view; } @Inject  DecisionNavigatorTreeView(final HTMLDivElement view,
                                     final HTMLDivElement items,
                                     final ManagedInstance<TreeItem> managedInstance,
                                     final Elemental2DomUtil util); }
DecisionNavigatorTreeView implements DecisionNavigatorTreePresenter.View { @Override public HTMLElement getElement() { return view; } @Inject  DecisionNavigatorTreeView(final HTMLDivElement view,
                                     final HTMLDivElement items,
                                     final ManagedInstance<TreeItem> managedInstance,
                                     final Elemental2DomUtil util); @Override void init(final DecisionNavigatorTreePresenter presenter); @Override HTMLElement getElement(); @Override void clean(); @Override void setup(final List<DecisionNavigatorItem> items); @Override void select(final String uuid); @Override void deselect(); }
DecisionNavigatorTreeView implements DecisionNavigatorTreePresenter.View { @Override public HTMLElement getElement() { return view; } @Inject  DecisionNavigatorTreeView(final HTMLDivElement view,
                                     final HTMLDivElement items,
                                     final ManagedInstance<TreeItem> managedInstance,
                                     final Elemental2DomUtil util); @Override void init(final DecisionNavigatorTreePresenter presenter); @Override HTMLElement getElement(); @Override void clean(); @Override void setup(final List<DecisionNavigatorItem> items); @Override void select(final String uuid); @Override void deselect();  }