@Test public void show() { popupView.show("mainText", "okButtonText", okButtonCommandMock); verify(fileTextMock, times(1)).setValue(eq("")); verify(okButtonMock, times(1)).setEnabled(eq(false)); }
@Override public void show(final String mainTitleText, final String okButtonText, final Command okCommand) { fileContents = ""; fileText.setValue(""); if (!acceptedExtension.isEmpty()) { file.setAccept(String.join(",", acceptedExtension)); } okButton.setEnabled(false); super.show(mainTitleText, okButtonText, okCommand); }
FileUploadPopupView extends AbstractScenarioPopupView implements FileUploadPopup { @Override public void show(final String mainTitleText, final String okButtonText, final Command okCommand) { fileContents = ""; fileText.setValue(""); if (!acceptedExtension.isEmpty()) { file.setAccept(String.join(",", acceptedExtension)); } okButton.setEnabled(false); super.show(mainTitleText, okButtonText, okCommand); } }
FileUploadPopupView extends AbstractScenarioPopupView implements FileUploadPopup { @Override public void show(final String mainTitleText, final String okButtonText, final Command okCommand) { fileContents = ""; fileText.setValue(""); if (!acceptedExtension.isEmpty()) { file.setAccept(String.join(",", acceptedExtension)); } okButton.setEnabled(false); super.show(mainTitleText, okButtonText, okCommand); }  }
FileUploadPopupView extends AbstractScenarioPopupView implements FileUploadPopup { @Override public void show(final String mainTitleText, final String okButtonText, final Command okCommand) { fileContents = ""; fileText.setValue(""); if (!acceptedExtension.isEmpty()) { file.setAccept(String.join(",", acceptedExtension)); } okButton.setEnabled(false); super.show(mainTitleText, okButtonText, okCommand); }  static void fileLoaded(String fileContents); @Override void init(); @Override void show(final String mainTitleText,
                     final String okButtonText,
                     final Command okCommand); @Override void show(final String mainTitleText,
                     final String uploadWarningText,
                     final String okButtonText,
                     final Command okCommand); @Override String getFileContents(); @Override String getFileName(); @Override void setAcceptedExtension(List<String> acceptedExtension); @EventHandler("chooseButton") void onChooseButtonClickEvent(ClickEvent clickEvent); @EventHandler("file") void onFileChangeEvent(ChangeEvent event); static native void readTextFile(JavaScriptObject files); }
FileUploadPopupView extends AbstractScenarioPopupView implements FileUploadPopup { @Override public void show(final String mainTitleText, final String okButtonText, final Command okCommand) { fileContents = ""; fileText.setValue(""); if (!acceptedExtension.isEmpty()) { file.setAccept(String.join(",", acceptedExtension)); } okButton.setEnabled(false); super.show(mainTitleText, okButtonText, okCommand); }  static void fileLoaded(String fileContents); @Override void init(); @Override void show(final String mainTitleText,
                     final String okButtonText,
                     final Command okCommand); @Override void show(final String mainTitleText,
                     final String uploadWarningText,
                     final String okButtonText,
                     final Command okCommand); @Override String getFileContents(); @Override String getFileName(); @Override void setAcceptedExtension(List<String> acceptedExtension); @EventHandler("chooseButton") void onChooseButtonClickEvent(ClickEvent clickEvent); @EventHandler("file") void onFileChangeEvent(ChangeEvent event); static native void readTextFile(JavaScriptObject files);  }