From 9c1f47399ea81bdd63e032fc4f655a3320ea47c6 Mon Sep 17 00:00:00 2001 From: Christian Stenger Date: Wed, 9 May 2018 08:02:02 +0200 Subject: [PATCH] Squish: Stabilize selectFromLocator() Calling it several times inside the same run results in unexpected behavior. The list of items inside the Locator gets filled asynchronously, so give it a chance to populate before trying to click something. Change-Id: I542a9fda37ae09e98e496d12a40d507a040bb247 Reviewed-by: Robert Loehning --- tests/system/shared/utils.py | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/system/shared/utils.py b/tests/system/shared/utils.py index 8d1ce8682b8..0b8fb5818fa 100644 --- a/tests/system/shared/utils.py +++ b/tests/system/shared/utils.py @@ -114,6 +114,7 @@ def selectFromLocator(filter, itemName = None): # clicking the wanted item # if you replace this by pressing ENTER, be sure that something is selected # otherwise you will run into unwanted behavior + snooze(1) wantedItem = waitForObjectItem("{type='QTreeView' unnamed='1' visible='1'}", itemName) doubleClick(wantedItem, 5, 5, 0, Qt.LeftButton)