Fix project/domain scope in dynamic_creds

Lately merged review [1] changed a nature of a condition
setting domain / project scope. Before identity_admin_domain_scope
was a trigger between domain and project scope, however after
[1] change got merged the domain scope is not set only when
identity_admin_domain_scope is true but also when domain_id or
domain_name of default_admin_creds are set.

identity_admin_domain_scope var should be the only var which decides
whether domain scope will be set or not - in other words, if it's
false it shouldn't matter whether domain_id/domain_name are set at all.

https: //review.opendev.org/c/openstack/tempest/+/686073
Change-Id: Ia6d31980d42861ba5d4f53f99ffd59d0bfed4dd9
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'