mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2026-09-03 20:52:56 -05: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:
@@ -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):
|
||||
"""
|
||||
|
||||
Reference in New Issue
Block a user