From ab9f8a4967f665d70efbcce8bdf7f993a1bf33de Mon Sep 17 00:00:00 2001 From: Linda Wang Date: Fri, 4 Aug 2017 02:08:04 +0000 Subject: Add domain name when creating projects and users Change-Id: Id06e20e3c87072531930130db66763f554b4649c Signed-off-by: Linda Wang --- snaps/openstack/tests/os_source_file_test.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/snaps/openstack/tests/os_source_file_test.py b/snaps/openstack/tests/os_source_file_test.py index da474a2..1617f91 100644 --- a/snaps/openstack/tests/os_source_file_test.py +++ b/snaps/openstack/tests/os_source_file_test.py @@ -145,17 +145,20 @@ class OSIntegrationTestCase(OSComponentTestCase): self.role = None if self.use_keystone: - self.keystone = keystone_utils.keystone_client(self.os_creds) + self.keystone = keystone_utils.keystone_client(self.admin_os_creds) guid = self.__class__.__name__ + '-' + str(uuid.uuid4())[:-19] project_name = guid + '-proj' self.project_creator = deploy_utils.create_project( - self.admin_os_creds, ProjectSettings(name=project_name)) + self.admin_os_creds, ProjectSettings( + name=project_name, + domain=self.admin_os_creds.project_domain_name)) self.user_creator = deploy_utils.create_user( self.admin_os_creds, UserSettings( name=guid + '-user', password=guid, project_name=project_name, roles={ - 'admin': self.project_creator.project_settings.name})) + 'admin': self.project_creator.project_settings.name}, + domain_name=self.admin_os_creds.user_domain_name)) self.os_creds = self.user_creator.get_os_creds( self.project_creator.project_settings.name) -- cgit 1.2.3-korg