'Call ``DELETE /domains/{domain_id}``.'

def test_delete_domain_hierarchy(self):

    domain = unit.new_domain_ref()
    self.resource_api.create_domain(domain['id'], domain)
    root_project = unit.new_project_ref(domain_id=domain['id'])
    root_project = self.resource_api.create_project(root_project['id'], root_project)
    leaf_project = unit.new_project_ref(domain_id=domain['id'], parent_id=root_project['id'])
    self.resource_api.create_project(leaf_project['id'], leaf_project)
    self.patch(('/domains/%(domain_id)s' % {'domain_id': domain['id']}), body={'domain': {'enabled': False}})
    self.delete(('/domains/%(domain_id)s' % {'domain_id': domain['id']}))
    self.assertRaises(exception.DomainNotFound, self.resource_api.get_domain, domain['id'])
    self.assertRaises(exception.ProjectNotFound, self.resource_api.get_project, root_project['id'])
    self.assertRaises(exception.ProjectNotFound, self.resource_api.get_project, leaf_project['id'])
