public void OwningDtoTest() { var dtos = new HashSet <DomainObjectDTO>(); // 1. Add barebones LP. const string lpGuid = "9719A466-2240-4DEA-9722-9FE0746A30A6"; var lpDto = CreatoDTO(dtos, lpGuid, "LangProject", null); const string lexDbGuid = "6C84F84A-5B99-4CF5-A7D5-A308DDC604E0"; var ldbDto = CreatoDTO(dtos, lexDbGuid, "LexDb", lpGuid); IDomainObjectDTORepository dtoRepos = new DomainObjectDtoRepository(1, dtos, m_mdc, null, TestDirectoryFinder.LcmDirectories); Assert.IsNull(dtoRepos.GetOwningDTO(lpDto), "LP has owner?"); var ldbOwner = dtoRepos.GetOwningDTO(ldbDto); Assert.IsNotNull(ldbOwner, "LexDB has no owner?"); Assert.AreSame(lpDto, ldbOwner, "LP not owner of LexDB?"); }