summaryrefslogtreecommitdiffstats
path: root/tests/auto/widgets/itemviews/qitemdelegate/tst_qitemdelegate.cpp
diff options
context:
space:
mode:
authorGiuseppe D'Angelo <giuseppe.dangelo@kdab.com>2022-04-26 00:35:21 +0200
committerGiuseppe D'Angelo <giuseppe.dangelo@kdab.com>2022-04-27 17:54:19 +0200
commit45b09215e51b84fd6d01e5d8a8cb8555c9099f0e (patch)
treefe3c339d7bf416e5fa2f0c6b6075c0a41dab8663 /tests/auto/widgets/itemviews/qitemdelegate/tst_qitemdelegate.cpp
parent0b5b98c4aecb023a880fe49444b3d8f01810b4f6 (diff)
tst_qitemdelegate: make it more robust
Remove a processEvents() call followed by a QCOMPARE and turn it into a QTRY_COMPARE. Otherwise it seems to be randomly failing on Ubuntu 22.04. Change-Id: I3c1b9d55c857c79ffd36aeb98971db60267adace Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Diffstat (limited to 'tests/auto/widgets/itemviews/qitemdelegate/tst_qitemdelegate.cpp')
-rw-r--r--tests/auto/widgets/itemviews/qitemdelegate/tst_qitemdelegate.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/tests/auto/widgets/itemviews/qitemdelegate/tst_qitemdelegate.cpp b/tests/auto/widgets/itemviews/qitemdelegate/tst_qitemdelegate.cpp
index 74a861a8c8..a1f0814be5 100644
--- a/tests/auto/widgets/itemviews/qitemdelegate/tst_qitemdelegate.cpp
+++ b/tests/auto/widgets/itemviews/qitemdelegate/tst_qitemdelegate.cpp
@@ -357,9 +357,8 @@ void tst_QItemDelegate::editorKeyPress()
QTest::keyClicks(editor, expected);
QTest::keyClick(editor, Qt::Key_Enter);
- QApplication::processEvents();
- QCOMPARE(index.data().toString(), expected);
+ QTRY_COMPARE(index.data().toString(), expected);
}
void tst_QItemDelegate::doubleEditorNegativeInput()