Fix flakiness of test on OpenSUSE/KDE

The cause is that the first EXPOSE event comes with the window not
having focus. See QTBUG-105177.

Fixes: QTBUG-67254
Task-number: QTBUG-105177
Change-Id: I04789d0a173979d9a60893989f76566b617c6576
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
This commit is contained in:
Dimitrios Apostolou 2022-07-25 16:54:24 +02:00
parent d8f9ac784e
commit 83090e16cb
2 changed files with 1 additions and 5 deletions

View File

@ -45,10 +45,6 @@ ubuntu-18.04
ubuntu-20.04
[conflictingGesturesInGraphicsView]
ubuntu-20.04
[customGesture]
opensuse-leap
# QTBUG-67254
opensuse-42.3
[graphicsItemTreeGesture]
ubuntu-18.04
ubuntu-20.04

View File

@ -337,7 +337,7 @@ void tst_Gestures::customGesture()
GestureWidget widget;
widget.grabGesture(CustomGesture::GestureType, Qt::DontStartGestureOnChildren);
widget.show();
QVERIFY(QTest::qWaitForWindowExposed(&widget));
QVERIFY(QTest::qWaitForWindowActive(&widget));
CustomEvent event;
event.hotSpot = widget.mapToGlobal(QPoint(5,5));