'Test the create_stack_domain_project function.'

def test_create_stack_domain_project(self):

    ctx = utils.dummy_context()
    self.patchobject(ctx, '_create_auth_plugin')
    ctx.trust_id = None
    expected_name = ('%s-astack' % ctx.tenant_id)
    self._stub_domain_admin_client()
    self.mock_admin_client.projects = self.m.CreateMockAnything()
    dummy = self.m.CreateMockAnything()
    dummy.id = 'aproject123'
    self.mock_admin_client.projects.create(name=expected_name, domain='adomain123', description='Heat    stack    user    project').AndReturn(dummy)
    self.m.ReplayAll()
    heat_ks_client = heat_keystoneclient.KeystoneClient(ctx)
    self.assertEqual('aproject123', heat_ks_client.create_stack_domain_project('astack'))
