### Question:
ActivityDataIOEditor implements ActivityDataIOEditorView.Presenter { public void configureDialog(final String taskName, final boolean hasInputVars, final boolean isSingleInputVar, final boolean hasOutputVars, final boolean isSingleOutputVar) { this.hasInputVars = hasInputVars; this.isSingleInputVar = isSingleInputVar; this.hasOutputVars = hasOutputVars; this.isSingleOutputVar = isSingleOutputVar; if (taskName != null && !taskName.isEmpty()) { view.setCustomViewTitle(taskName); } else { view.setDefaultViewTitle(); } view.setInputAssignmentsVisibility(hasInputVars); view.setOutputAssignmentsVisibility(hasOutputVars); view.setIsInputAssignmentSingleVar(isSingleInputVar); view.setIsOutputAssignmentSingleVar(isSingleOutputVar); }  @PostConstruct void init(); void setCallback(final GetDataCallback callback); @Override void handleOkClick(); @Override void handleCancelClick(); void setDataTypes(final List<String> dataTypes,
                             final List<String> dataTypeDisplayNames); void setAssignmentData(final AssignmentData assignmentData); void configureDialog(final String taskName,
                                final boolean hasInputVars,
                                final boolean isSingleInputVar,
                                final boolean hasOutputVars,
                                final boolean isSingleOutputVar); void setDisallowedPropertyNames(final List<String> disallowedPropertyNames); void setProcessVariables(final List<String> processVariables); void setInputAssignmentRows(final List<AssignmentRow> inputAssignmentRows); void setOutputAssignmentRows(final List<AssignmentRow> outputAssignmentRows); void setReadOnly(final boolean readOnly); void show(); @Override ListBoxValues.ValueTester dataTypesTester(); @Override ListBoxValues.ValueTester processVarTester();  }### Answer:
@Test public void testConfigureDialogBoolean() { ioEditor.configureDialog("task name", true, false, true, false); verify(ioEditorView).setInputAssignmentsVisibility(true); verify(ioEditorView).setIsInputAssignmentSingleVar(false); verify(ioEditorView).setOutputAssignmentsVisibility(true); verify(ioEditorView).setIsOutputAssignmentSingleVar(false); ioEditor.configureDialog("task name", false, true, false, true); verify(ioEditorView).setInputAssignmentsVisibility(false); verify(ioEditorView).setIsInputAssignmentSingleVar(true); verify(ioEditorView).setOutputAssignmentsVisibility(false); verify(ioEditorView).setIsOutputAssignmentSingleVar(true); }
@Test public void testConfigureDialogTaskNameEmpty() { ioEditor.configureDialog("", true, true, true, true); verify(ioEditorView, times(1)).setDefaultViewTitle(); verify(ioEditorView, never()).setCustomViewTitle(anyString()); }
@Test public void testConfigureDialogTaskNameNull() { ioEditor.configureDialog(null, true, true, true, true); verify(ioEditorView, times(1)).setDefaultViewTitle(); verify(ioEditorView, never()).setCustomViewTitle(anyString()); }
@Test public void testConfigureDialogTaskNameCustom() { ioEditor.configureDialog("abc", true, true, true, true); verify(ioEditorView, times(1)).setCustomViewTitle("abc"); verify(ioEditorView, never()).setDefaultViewTitle(); }