WorkbenchLayoutImpl implements WorkbenchLayout { void setHeaderContents(List<Header> headers) { DOMUtil.removeAllChildren(headerPanel); if (!headers.isEmpty()) { for (Header h : headers) { headerPanel.appendChild(h.getElement()); } root.setHeaderWidget(createWidgetFrom(headerPanel)); } } WorkbenchLayoutImpl(); @Inject  WorkbenchLayoutImpl(SyncBeanManager iocManager,
                               HeaderPanel root,
                               WorkbenchDragAndDropManager dndManager,
                               UberfireDocksContainer uberfireDocksContainer,
                               WorkbenchPickupDragController dragController,
                               Div headerPanel,
                               Div footerPanel); @Override HeaderPanel getRoot(); @Override HasWidgets getPerspectiveContainer(); @Override void onBootstrap(); @Override void onResize(); @Override void resizeTo(int width,
                         int height); @Override void maximize(final Widget w); @Override void maximize(final Widget w,
                         final Command callback); @Override void unmaximize(final Widget w); @Override void unmaximize(final Widget w,
                           final Command callback); @Override void setMarginWidgets(boolean isStandaloneMode,
                                 Set<String> headersToKeep); void addWorkbenchProfileCssClass(@Observes WorkbenchProfileCssClass workbenchProfileCssClass); static final String UF_MAXIMIZED_PANEL; static final String UF_ROOT_CSS_CLASS; }
@Test public void setHeaderContentsTest() { Div headerPanel = workbenchLayout.getHeaderPanel(); List<Header> headers = Arrays.asList(header1, header2); workbenchLayout.setHeaderContents(headers); verify(headerPanel, times(2)).appendChild(any()); verify(root).setHeaderWidget(any()); }