Merge "Fix project/domain scope in dynamic_creds"
diff --git a/tempest/lib/common/dynamic_creds.py b/tempest/lib/common/dynamic_creds.py
index 0a2817b..d9f4f46 100644
--- a/tempest/lib/common/dynamic_creds.py
+++ b/tempest/lib/common/dynamic_creds.py
@@ -144,9 +144,9 @@
# need a different token scope for them.
if self.default_admin_creds.system:
scope = 'system'
- elif (self.default_admin_creds.domain_id or
- self.default_admin_creds.domain_name or
- self.identity_admin_domain_scope):
+ elif (self.identity_admin_domain_scope and
+ (self.default_admin_creds.domain_id or
+ self.default_admin_creds.domain_name)):
scope = 'domain'
else:
scope = 'project'