### Question:
ServerManagementBrowserPresenter { @OnOpen public void onOpen() { refreshList( new ServerTemplateListRefresh() ); } @Inject  ServerManagementBrowserPresenter( final Logger logger,
                                             final View view,
                                             final ServerNavigationPresenter navigationPresenter,
                                             final ServerTemplatePresenter serverTemplatePresenter,
                                             final ServerEmptyPresenter serverEmptyPresenter,
                                             final ServerContainerEmptyPresenter serverContainerEmptyPresenter,
                                             final ContainerPresenter containerPresenter,
                                             final RemotePresenter remotePresenter,
                                             final Caller<SpecManagementService> specManagementService,
                                             final Event<ServerTemplateSelected> serverTemplateSelectedEvent,
                                             final Event<NotificationEvent> notification ); @PostConstruct void init(); @OnOpen void onOpen(); void onServerDeleted( @Observes final ServerTemplateDeleted serverTemplateDeleted ); void onSelected( @Observes final ServerTemplateSelected serverTemplateSelected ); void onSelected( @Observes final ContainerSpecSelected containerSpecSelected ); void onSelected( @Observes final ServerInstanceSelected serverInstanceSelected ); void onContainerUpdate( @Observes final ContainerUpdateEvent containerUpdateEvent ); void setup( final Collection<ServerTemplateKey> serverTemplateKeys,
                       final String selectServerTemplateId ); void onServerTemplateUpdated( @Observes final ServerTemplateUpdated serverTemplateUpdated ); void onDelete( @Observes final ServerInstanceDeleted serverInstanceDeleted ); @WorkbenchPartTitle String getTitle(); @WorkbenchPartView IsWidget getView();  }### Answer:
@Test public void testOnOpen() { final ServerTemplateKey serverTemplateKey = new ServerTemplateKey( "ServerTemplateKeyId", "ServerTemplateKeyName" ); final List<ServerTemplateKey> serverTemplateKeys = Collections.singletonList( serverTemplateKey ); when( specManagementService.listServerTemplateKeys() ).thenReturn( new ServerTemplateKeyList(serverTemplateKeys) ); presenter.onOpen(); verify( navigationPresenter ).setup( serverTemplateKey, serverTemplateKeys ); final ArgumentCaptor<ServerTemplateSelected> templateSelectedCaptor = ArgumentCaptor.forClass( ServerTemplateSelected.class ); verify( serverTemplateSelectedEvent ).fire( templateSelectedCaptor.capture() ); assertEquals( serverTemplateKey, templateSelectedCaptor.getValue().getServerTemplateKey() ); }