summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorRobert Löhning <robert.loehning@qt.io>2023-05-04 22:21:06 +0200
committerRobert Löhning <robert.loehning@qt.io>2023-05-05 09:35:38 +0000
commit200d3b455b086858dc0cc9e847a7b0636454e5b1 (patch)
treeb3e8b55531e743c0638c6310cb2f21459377a19f /tests
parent8d03220017bf7e5c7be51fc36acb56fbde9e3e13 (diff)
downloadqt-creator-200d3b455b086858dc0cc9e847a7b0636454e5b1.tar.gz
SquishTests: Don't test.verify state of checkbox in getBuildIssues
- It generates a ridiculously large number of test results in comparison to what's actually tested - In tst_memberoperator, it is used in waitFor(). Thus, it depends on timing and the number of test results varies from one execution to another Change-Id: I7d4ad8f87590b4fc2dda51e9eda703961c7acd9e Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Diffstat (limited to 'tests')
-rw-r--r--tests/system/shared/build_utils.py2
-rw-r--r--tests/system/shared/utils.py10
2 files changed, 6 insertions, 6 deletions
diff --git a/tests/system/shared/build_utils.py b/tests/system/shared/build_utils.py
index 9f9608a0c0..dd7677d473 100644
--- a/tests/system/shared/build_utils.py
+++ b/tests/system/shared/build_utils.py
@@ -25,7 +25,7 @@ def toggleIssuesFilter(filterName, checked):
def getBuildIssues(ignoreCodeModel=True):
- ensureChecked(":Qt Creator_Issues_Core::Internal::OutputPaneToggleButton")
+ ensureChecked(":Qt Creator_Issues_Core::Internal::OutputPaneToggleButton" , silent=True)
model = waitForObject(":Qt Creator.Issues_QListView").model()
if ignoreCodeModel:
# filter out possible code model issues present inside the Issues pane
diff --git a/tests/system/shared/utils.py b/tests/system/shared/utils.py
index aa70220407..9b4f2dc95a 100644
--- a/tests/system/shared/utils.py
+++ b/tests/system/shared/utils.py
@@ -25,7 +25,8 @@ def verifyChecked(objectName, checked=True):
test.compare(object.checked, checked)
return object
-def ensureChecked(objectName, shouldBeChecked = True, timeout=20000):
+
+def ensureChecked(objectName, shouldBeChecked=True, timeout=20000, silent=False):
if shouldBeChecked:
targetState = Qt.Checked
state = "checked"
@@ -39,14 +40,13 @@ def ensureChecked(objectName, shouldBeChecked = True, timeout=20000):
while not waitFor('widget.checkState() == targetState', 1500) and clicked < 2:
clickButton(widget)
clicked += 1
- test.verify(waitFor("widget.checkState() == targetState", 1000))
+ silent or test.verify(waitFor("widget.checkState() == targetState", 1000))
except:
# widgets not derived from QCheckbox don't have checkState()
if not waitFor('widget.checked == shouldBeChecked', 1500):
mouseClick(widget)
- test.verify(waitFor("widget.checked == shouldBeChecked", 1000))
- test.log("New state for QCheckBox: %s" % state,
- str(objectName))
+ silent or test.verify(waitFor("widget.checked == shouldBeChecked", 1000))
+ silent or test.log("New state for QCheckBox: %s" % state, str(objectName))
return widget
# verify that an object is in an expected enable state. Returns the object.