qt5base-lts/tests/auto/widgets/graphicsview/qgraphicsview
Kari Oikarinen 141582505f Stabilize tst_QGraphicsView::acceptMouseDoubleClickEvent
This test has been flaky on openSUSE in CI. The problem was that the window is
sometimes resized or removed while processing events after adding the rectangle
item to the QGraphicsScene. When the same mouse event is reused again, it uses
wrong screen coordinates. QGraphicsScene handling of mouse events then looks for
items under cursor at the wrong coordinates, does not find any items and thus
doesn't accept the mouse event.

Fix by using QTest API for simulating mouse events. Also wait for changed signal
rather than blindly running one iteration of event loop.

Task-number: QTBUG-67212
Task-number: QTBUG-66216
Change-Id: I968f9470c6f8803d01cebeda6f12ad76b4fd5293
Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
2018-03-22 13:35:51 +00:00
..
.gitignore Moved tests into integrationtests/ and widgets/ 2011-10-20 19:45:41 +02:00
BLACKLIST Blacklist tst_QGraphicsView::itemsInRect_cosmeticAdjust on Ubuntu 2018-03-05 07:27:17 +00:00
qgraphicsview.pro testlib: start sharing common helper functions 2017-11-04 20:11:22 +00:00
tst_qgraphicsview_2.cpp tst_qgraphicsview: use new QTest::addRow() more 2017-01-26 10:31:36 +00:00
tst_qgraphicsview.cpp Stabilize tst_QGraphicsView::acceptMouseDoubleClickEvent 2018-03-22 13:35:51 +00:00
tst_qgraphicsview.h Speed up compilation of tst_qgraphicsview_2.cpp 2016-10-03 14:59:56 +00:00