### Question:
DataObjectTypeWidget extends Composite implements HasValue<DataObjectTypeValue>,
                                                               ComboBoxView.ModelPresenter { public void setReadOnly(boolean readOnly) { dataType.setEnabled(!readOnly); dataTypeComboBox.setReadOnly(readOnly); customDataType.setEnabled(!readOnly); } @Inject  DataObjectTypeWidget(final SessionManager sessionManager); @PostConstruct void init(); static Map<String, String> getMapDataTypeNamesToDisplayNames(); Path getDiagramPath(); @Override DataObjectTypeValue getValue(); @Override void setValue(DataObjectTypeValue value); @Override void setValue(DataObjectTypeValue value, boolean fireEvents); @Override HandlerRegistration addValueChangeHandler(ValueChangeHandler<DataObjectTypeValue> handler); void setReadOnly(boolean readOnly); @Override void setTextBoxModelValue(TextBox textBox, String value); @Override void setListBoxModelValue(ValueListBox<String> listBox, String value); @Override String getModelValue(ValueListBox<String> listBox); @Override void notifyModelChanged();  }### Answer:
@Test public void testSetReadOnlyTrue() { widget.setReadOnly(true); verify(dataTypeComboBox, times(1)).setReadOnly(true); }
@Test public void testSetReadOnlyFalse() { widget.setReadOnly(false); verify(dataTypeComboBox, times(1)).setReadOnly(false); }