Fix Identity functional tests to not require OS_AUTH_URL
The Identity functional tests had an assumption that OS_AUTH_URL would always be present, but when running the functional tests and only setting OS_CLOUD (using clouds.yaml for creds) this fell down. Change-Id: Ie589d301f866b06d9f8be8deeb953e03bc01cf09
This commit is contained in:
parent
b69b539a42
commit
d780e9e91f
@ -44,8 +44,8 @@ class IdentityTests(base.TestCase):
|
|||||||
# prepare v2 env
|
# prepare v2 env
|
||||||
os.environ['OS_IDENTITY_API_VERSION'] = '2.0'
|
os.environ['OS_IDENTITY_API_VERSION'] = '2.0'
|
||||||
auth_url = os.environ.get('OS_AUTH_URL')
|
auth_url = os.environ.get('OS_AUTH_URL')
|
||||||
auth_url = auth_url.replace('v3', 'v2.0')
|
if auth_url:
|
||||||
os.environ['OS_AUTH_URL'] = auth_url
|
os.environ['OS_AUTH_URL'] = auth_url.replace('v3', 'v2.0')
|
||||||
|
|
||||||
# create dummy project
|
# create dummy project
|
||||||
cls.project_name = data_utils.rand_name('TestProject')
|
cls.project_name = data_utils.rand_name('TestProject')
|
||||||
|
@ -56,8 +56,8 @@ class IdentityTests(base.TestCase):
|
|||||||
# prepare v3 env
|
# prepare v3 env
|
||||||
os.environ['OS_IDENTITY_API_VERSION'] = '3'
|
os.environ['OS_IDENTITY_API_VERSION'] = '3'
|
||||||
auth_url = os.environ.get('OS_AUTH_URL')
|
auth_url = os.environ.get('OS_AUTH_URL')
|
||||||
auth_url = auth_url.replace('v2.0', 'v3')
|
if auth_url:
|
||||||
os.environ['OS_AUTH_URL'] = auth_url
|
os.environ['OS_AUTH_URL'] = auth_url.replace('v2.0', 'v3')
|
||||||
|
|
||||||
# create dummy domain
|
# create dummy domain
|
||||||
cls.domain_name = data_utils.rand_name('TestDomain')
|
cls.domain_name = data_utils.rand_name('TestDomain')
|
||||||
|
Loading…
Reference in New Issue
Block a user