mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
Fix UI_driver.has_class exception. Handle situation when element has no class attribute
Reviewed-By: Alexander Bokovoy <abokovoy@redhat.com> Reviewed-By: Petr Vobornik <pvoborni@redhat.com>
This commit is contained in:
parent
1affddaabe
commit
46eb9a38f0
@ -1908,7 +1908,8 @@ class UI_driver(object):
|
||||
"""
|
||||
Check if el has CSS class
|
||||
"""
|
||||
return cls in el.get_attribute("class").split()
|
||||
class_attr = el.get_attribute("class")
|
||||
return bool(class_attr) and cls in class_attr.split()
|
||||
|
||||
def skip(self, reason):
|
||||
"""
|
||||
|
Loading…
Reference in New Issue
Block a user