test
This commit is contained in:
parent
3f714531ad
commit
42442755c4
|
@ -16,7 +16,7 @@ class ToastMessage(QObject):
|
|||
@allure.step('Get toast messages')
|
||||
def get_toast_messages(self) -> typing.List[str]:
|
||||
messages = []
|
||||
for child in walk_children(self.object):
|
||||
for child in walk_children(self.object_exists):
|
||||
if getattr(child, 'id', '') == 'title':
|
||||
messages.append(str(child.text))
|
||||
if len(messages) == 0:
|
||||
|
|
|
@ -23,6 +23,11 @@ class QObject:
|
|||
def object(self):
|
||||
return driver.waitForObject(self.real_name, configs.timeouts.UI_LOAD_TIMEOUT_MSEC)
|
||||
|
||||
@property
|
||||
@allure.step('Get object {0}')
|
||||
def object_exists(self):
|
||||
return driver.waitForObjectExists(self.real_name, configs.timeouts.UI_LOAD_TIMEOUT_MSEC)
|
||||
|
||||
@property
|
||||
@allure.step('Get object exists {0}')
|
||||
def exists(self) -> bool:
|
||||
|
|
Loading…
Reference in New Issue