@Test public void testConfigure() throws Exception { FileUploadEditor.FileUploadEditorCallback callback = mock(FileUploadEditor.FileUploadEditorCallback.class); presenter.configure("f1", callback); assertEquals(view.asWidget(), presenter.asWidget()); assertEquals(callback, presenter.callback); verify(view, times(0)).init(presenter); verify(view, times(0)).addHelpContent(anyString(), anyString(), any(Placement.class)); verify(view, times(1)).setFileUploadName("f1"); verify(view, times(0)).setFileUploadVisible(anyBoolean()); verify(view, times(0)).setFileLabelText(anyString()); verify(view, times(0)).setFileLabelVisible(anyBoolean()); verify(view, times(0)).setLoadingImageVisible(false); verify(view, times(0)).getFileName(); verify(view, times(0)).setFormAction(anyString()); verify(view, times(0)).submit(); verify(view, times(0)).showError(any(SafeHtml.class)); verify(view, times(0)).clearError(); }
public void configure(final String fileUploadName, final FileUploadEditorCallback callback) { view.setFileUploadName(fileUploadName); this.callback = callback; }
FileUploadEditor implements IsWidget, LeafAttributeEditor<String> { public void configure(final String fileUploadName, final FileUploadEditorCallback callback) { view.setFileUploadName(fileUploadName); this.callback = callback; } }
FileUploadEditor implements IsWidget, LeafAttributeEditor<String> { public void configure(final String fileUploadName, final FileUploadEditorCallback callback) { view.setFileUploadName(fileUploadName); this.callback = callback; } @Inject  FileUploadEditor(final Event<org.dashbuilder.common.client.event.ValueChangeEvent<String>> valueChangeEvent,
                            final Event<NotificationEvent> workbenchNotification,
                            final View view); }
FileUploadEditor implements IsWidget, LeafAttributeEditor<String> { public void configure(final String fileUploadName, final FileUploadEditorCallback callback) { view.setFileUploadName(fileUploadName); this.callback = callback; } @Inject  FileUploadEditor(final Event<org.dashbuilder.common.client.event.ValueChangeEvent<String>> valueChangeEvent,
                            final Event<NotificationEvent> workbenchNotification,
                            final View view); @PostConstruct void init(); void configure(final String fileUploadName, final FileUploadEditorCallback callback); void addHelpContent(final String title, final String content, final Placement placement); @Override void showErrors(List<EditorError> errors); @Override Widget asWidget(); @Override void setValue(final String value); @Override String getValue(); }
FileUploadEditor implements IsWidget, LeafAttributeEditor<String> { public void configure(final String fileUploadName, final FileUploadEditorCallback callback) { view.setFileUploadName(fileUploadName); this.callback = callback; } @Inject  FileUploadEditor(final Event<org.dashbuilder.common.client.event.ValueChangeEvent<String>> valueChangeEvent,
                            final Event<NotificationEvent> workbenchNotification,
                            final View view); @PostConstruct void init(); void configure(final String fileUploadName, final FileUploadEditorCallback callback); void addHelpContent(final String title, final String content, final Placement placement); @Override void showErrors(List<EditorError> errors); @Override Widget asWidget(); @Override void setValue(final String value); @Override String getValue(); public View view; }