SquishTests: Stabilize welcome page related tests

Change-Id: I3596f2d1f7ca2de27a25075309ccb6015a1bb619
Reviewed-by: Robert Löhning <robert.loehning@qt.io>
This commit is contained in:
Christian Stenger
2024-03-20 15:24:19 +01:00
parent 19fd7e15e3
commit 4cb18ded74
2 changed files with 3 additions and 2 deletions

View File

@@ -14,8 +14,9 @@ def clickItemVerifyHelpCombo(button, expectedHelpComboRegex, testDetails):
test.log("Found %s" % str(helpCombo.currentText))
# select "Welcome" page from left toolbar again
switchViewTo(ViewConstants.WELCOME)
return test.verify(object.exists(getWelcomeScreenSideBarButton(getStarted)),
return test.verify(checkIfObjectExists(getWelcomeScreenSideBarButton(getStarted), timeout=1000),
"Verifying: '%s' button is being displayed." % getStarted)
def buttonActive(button):
return waitForObject(button).checked

View File

@@ -85,7 +85,7 @@ def createAndSwitchToSession(toSession):
def checkWelcomePage(sessionName, isCurrent=False):
switchViewTo(ViewConstants.WELCOME)
wsButton = getWelcomeScreenSideBarButton('Projects')
if not object.exists(wsButton):
if not checkIfObjectExists(wsButton, timeout=1000):
test.fatal("Something's pretty wrong - leaving check for WelcomePage.")
return
mouseClick(wsButton)