'Ensure domain drivers are reloaded on a config modification.'

def test_reloading_domain_config(self):

    domain_cfgs = self.identity_api.domain_configs
    new_config = {'ldap': {'url': uuid.uuid4().hex}, 'identity': {'driver': 'ldap'}}
    self.domain_config_api.create_config(CONF.identity.default_domain_id, new_config)
    default_config = domain_cfgs.get_domain_conf(CONF.identity.default_domain_id)
    self.assertEqual(new_config['ldap']['url'], default_config.ldap.url)
    updated_config = {'url': uuid.uuid4().hex}
    self.domain_config_api.update_config(CONF.identity.default_domain_id, updated_config, group='ldap', option='url')
    default_config = domain_cfgs.get_domain_conf(CONF.identity.default_domain_id)
    self.assertEqual(updated_config['url'], default_config.ldap.url)
    self.domain_config_api.delete_config(CONF.identity.default_domain_id)
    default_config = domain_cfgs.get_domain_conf(CONF.identity.default_domain_id)
    self.assertEqual(CONF.ldap.url, default_config.ldap.url)
