'Test error path when config lacks domain config.'

def test_init_domain_cfg_not_set_error(self):

    cfg.CONF.clear_override('stack_domain_admin')
    cfg.CONF.clear_override('stack_domain_admin_password')
    err = self.assertRaises(exception.Error, config.startup_sanity_check)
    exp_msg = 'heat.conf    misconfigured,    cannot    specify    "stack_user_domain_id"    or    "stack_user_domain_name"    without    "stack_domain_admin"    and    "stack_domain_admin_password"'
    self.assertIn(exp_msg, six.text_type(err))
