Address consider-using-in

Replace multiple comparisons with 'in' operation.

See: https://pagure.io/freeipa/issue/7758
Signed-off-by: Christian Heimes <cheimes@redhat.com>
Reviewed-By: Alexander Bokovoy <abokovoy@redhat.com>
This commit is contained in:
Christian Heimes 2018-11-09 11:20:28 +01:00
parent 7bdc9badfd
commit 496d1756c9
2 changed files with 2 additions and 2 deletions

View File

@ -215,7 +215,7 @@ class UI_driver:
)
else:
try:
if browser == 'chrome' or browser == 'chromium':
if browser in {'chrome', 'chromium'}:
driver = webdriver.Chrome(chrome_options=options)
elif browser == 'ie':
driver = webdriver.Ie()

View File

@ -160,7 +160,7 @@ class StageUserTracker(KerberosAliasMixin, Tracker):
elif key == u'ipasshpubkey':
self.attrs[u'sshpubkeyfp'] = [sshpubkeyfp]
self.attrs[key] = [self.kwargs[key]]
elif key == u'random' or key == u'userpassword':
elif key in {u'random', u'userpassword'}:
self.attrs[u'krbextradata'] = [Fuzzy(type=bytes)]
self.attrs[u'krbpasswordexpiration'] = [
fuzzy_dergeneralizedtime]