public void Establishes_correct_class_hierarchy() { CodeModelFactory factory = new CodeModelFactory(); List <CaDETClass> classes = factory.CreateProject(_testDataFactory.GetClassesWithHierarchy()).Classes; var doctor = classes.Find(c => c.Name.Equals("Doctor")); var employee = classes.Find(c => c.Name.Equals("Employee")); var entity = classes.Find(c => c.Name.Equals("Entity")); doctor.Parent.ShouldBe(employee); employee.Parent.ShouldBe(entity); entity.Parent.ShouldBeNull(); doctor.FindMember("Doctor").AccessedAccessors.ShouldContain(employee.FindMember("Email")); employee.FindMember("Employee").AccessedAccessors.ShouldContain(entity.FindMember("Id")); }