### Question:
DataObjectService extends AbstractEntityTypeService<DataObject, DataTypeDto> implements IDataObjectService, GroupServiceUtilizer<DataObjectDto>, CategoryServiceUtilizer<DataObjectDto> { @Override public void deleteDataType(String dataTypeCode) { super.deleteEntityType(SystemConstants.DATA_OBJECT_MANAGER, dataTypeCode); }  void setDtoBuilder(IDtoBuilder<DataObject, DataObjectDto> dtoBuilder); @Override PagedMetadata<EntityTypeShortDto> getShortDataTypes(RestListRequest requestList); @Override DataTypeDto getDataType(String dataTypeCode); @Override DataTypeDto addDataType(DataTypeDtoRequest bodyRequest, BindingResult bindingResult); @Override DataTypeDto updateDataType(DataTypeDtoRequest request, BindingResult bindingResult); @Override void deleteDataType(String dataTypeCode); @Override PagedMetadata<String> getAttributeTypes(RestListRequest requestList); @Override AttributeTypeDto getAttributeType(String attributeCode); @Override EntityTypeAttributeFullDto getDataTypeAttribute(String dataTypeCode, String attributeCode); @Override EntityTypeAttributeFullDto addDataTypeAttribute(String dataTypeCode, EntityTypeAttributeFullDto bodyRequest, BindingResult bindingResult); @Override EntityTypeAttributeFullDto updateDataTypeAttribute(String dataTypeCode, EntityTypeAttributeFullDto bodyRequest, BindingResult bindingResult); @Override void deleteDataTypeAttribute(String dataTypeCode, String attributeCode); @Override void moveDataTypeAttribute(String dataTypeCode, String attributeCode, boolean moveUp); @Override void reloadDataTypeReferences(String dataTypeCode); @Override Map<String, Integer> reloadDataTypesReferences(List<String> dataTypeCodes); @Override EntityTypesStatusDto getDataTypesRefreshStatus(); void setPageManager(IPageManager pageManager); void setDataObjectModelManager(IDataObjectModelManager dataObjectModelManager); @Override String getManagerName(); @Override List<DataObjectDto> getGroupUtilizer(String groupCode); @Override List getCategoryUtilizer(String categoryCode);  }### Answer:
@Test(expected = ValidationConflictException.class) public void deleteReferencedDataType() throws Throwable { when(this.dataObjectManager.getName()).thenReturn(SystemConstants.DATA_OBJECT_MANAGER); DataObject dataObject = new DataObject(); dataObject.setTypeCode("ABC"); when(this.dataObjectManager.getEntityPrototype("ABC")).thenReturn(dataObject); List<String> list = new ArrayList<>(); list.add("ABC123"); when(this.dataObjectManager.searchId("ABC", null)).thenReturn(list); this.dataObjectService.deleteDataType("ABC"); }