Resolve pep8 violations

This commit is contained in:
Adam Dyess
2020-01-22 09:33:58 -06:00
parent 59b06a956b
commit b75aaa79c5
2 changed files with 10 additions and 4 deletions
+6 -2
View File
@@ -416,13 +416,17 @@ class LdapTests(BaseKeystoneTest):
application_name = 'keystone-ldap'
can_config, config = self._get_ldap_config()
if not can_config:
raise unittest.SkipTest("Skipping API tests as no LDAP test fixture")
raise unittest.SkipTest(
"Skipping API tests as no LDAP test fixture"
)
with self.config_change(
self.config_current(application_name),
config,
application_name=application_name):
logging.info('Waiting for users to become available in keystone...')
logging.info(
'Waiting for users to become available in keystone...'
)
states = {
'keystone': {
'workload-status': 'idle',
+4 -2
View File
@@ -134,7 +134,7 @@ class OpenStackBaseTest(unittest.TestCase):
logging.debug('Leader unit is {}'.format(cls.lead_unit))
def config_current(self, application_name=None, keys=None):
"""Get Current Config of an application normalized into key-values
"""Get Current Config of an application normalized into key-values.
:param application_name: String application name for use when called
by a charm under test other than the object's
@@ -185,7 +185,9 @@ class OpenStackBaseTest(unittest.TestCase):
# we need to compare config values to what is already applied before
# attempting to set them. otherwise the model will behave differently
# than we would expect while waiting for completion of the change
app_config = self.config_current(application_name, keys=alternate_config.keys())
app_config = self.config_current(
application_name, keys=alternate_config.keys()
)
if all(item in app_config.items()
for item in alternate_config.items()):