### Question:
ContainerCardPresenter { public void setup( final ServerInstanceKey serverInstanceKey, final Container container ) { linkTitlePresenter = presenterProvider.select( LinkTitlePresenter.class ).get(); bodyPresenter = presenterProvider.select( BodyPresenter.class ).get(); footerPresenter = presenterProvider.select( FooterPresenter.class ).get(); updateContent( serverInstanceKey, container ); final CardPresenter card = presenterProvider.select( CardPresenter.class ).get(); card.addTitle( linkTitlePresenter ); card.addBody( bodyPresenter ); card.addFooter( footerPresenter ); view.setCard( card.getView() ); } @Inject  ContainerCardPresenter( final View view,
                                   final ManagedInstance<Object> presenterProvider,
                                   final Event<ServerInstanceSelected> remoteServerSelectedEvent ); View getView(); void setup( final ServerInstanceKey serverInstanceKey,
                       final Container container ); void delete(); void updateContent( final ServerInstanceKey serverInstanceKey,
                               final Container container );  }### Answer:
@Test public void testSetup() { final LinkTitlePresenter linkTitlePresenter = spy( new LinkTitlePresenter( mock( LinkTitlePresenter.View.class ) ) ); when( linkTitlePresenterProvider.get() ).thenReturn( linkTitlePresenter ); final BodyPresenter bodyPresenter = mock( BodyPresenter.class ); when( bodyPresenterProvider.get() ).thenReturn( bodyPresenter ); final FooterPresenter footerPresenter = mock( FooterPresenter.class ); when( footerPresenterProvider.get() ).thenReturn( footerPresenter ); final CardPresenter.View cardPresenterView = mock( CardPresenter.View.class ); final CardPresenter cardPresenter = spy( new CardPresenter( cardPresenterView ) ); when( cardPresenterProvider.get() ).thenReturn( cardPresenter ); final ServerInstanceKey serverInstanceKey = new ServerInstanceKey( "templateId", "serverName", "serverInstanceId", "url" ); final Message message = new Message( Severity.INFO, "testMessage" ); final ReleaseId resolvedReleasedId = new ReleaseId( "org.kie", "container", "1.0.0" ); final Container container = new Container( "containerSpecId", "containerName", serverInstanceKey, Collections.singletonList( message ), resolvedReleasedId, null ); presenter.setup( serverInstanceKey, container ); verify( linkTitlePresenter ).setup( eq( serverInstanceKey.getServerName() ), any( Command.class ) ); verify( bodyPresenter ).setup( Arrays.asList( message ) ); verify( footerPresenter ).setup( container.getUrl(), resolvedReleasedId.getVersion() ); verify( cardPresenter ).addTitle( linkTitlePresenter ); verify( cardPresenter ).addBody( bodyPresenter ); verify( cardPresenter ).addFooter( footerPresenter ); verify( view ).setCard( cardPresenterView ); linkTitlePresenter.onSelect(); verify( remoteServerSelectedEvent ).fire( eq( new ServerInstanceSelected( serverInstanceKey ) ) ); }