diff --git a/test/e2e/driver/squish_api.py b/test/e2e/driver/squish_api.py index 7a0a7f35d6..8af30d0ce2 100644 --- a/test/e2e/driver/squish_api.py +++ b/test/e2e/driver/squish_api.py @@ -13,5 +13,5 @@ def waitFor(condition, timeout_msec: int = configs.timeouts.UI_LOAD_TIMEOUT_MSEC return True -def isFrozen(timeout_msec): - return driver.currentApplicationContext().isFrozen(timeout_msec) +def isFrozen(timeout_sec): + return driver.currentApplicationContext().isFrozen(timeout_sec) diff --git a/test/e2e/gui/elements/object.py b/test/e2e/gui/elements/object.py index 71007eef60..b5010699c4 100644 --- a/test/e2e/gui/elements/object.py +++ b/test/e2e/gui/elements/object.py @@ -100,6 +100,7 @@ class QObject: x: int = None, y: int = None, button=None, + timeout=1, ): driver.mouseClick( self.object, @@ -108,6 +109,13 @@ class QObject: button or driver.Qt.LeftButton ) LOG.info('%s: is clicked with Qt.LeftButton', self) + LOG.info("Checking if application context is frozen") + + if not isFrozen(timeout): + pass + else: + LOG.info("Application context did not respond after click") + raise Exception(f'Application UI is not responding within {timeout} second(s)') @allure.step('Native click {0}') def native_mouse_click(