From 203721da4d1fe32a92854ca8edd9e47339832e30 Mon Sep 17 00:00:00 2001 From: Paul Olav Tvete Date: Fri, 11 Sep 2009 14:04:03 +0200 Subject: Better failure message when it fails Some platforms do not recalculate the Qt::WA_UnderMouse attribute when a widget is shown underneath the mouse. Reviewed-by: Olivier --- tests/auto/qstylesheetstyle/tst_qstylesheetstyle.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/auto/qstylesheetstyle/tst_qstylesheetstyle.cpp b/tests/auto/qstylesheetstyle/tst_qstylesheetstyle.cpp index 9d76741..491330b 100644 --- a/tests/auto/qstylesheetstyle/tst_qstylesheetstyle.cpp +++ b/tests/auto/qstylesheetstyle/tst_qstylesheetstyle.cpp @@ -850,6 +850,8 @@ void tst_QStyleSheetStyle::hoverColors() QTest::mouseMove ( widget, QPoint(5,5)); QTest::qWait(60); + QVERIFY(widget->testAttribute(Qt::WA_UnderMouse)); + QImage image(frame.width(), frame.height(), QImage::Format_ARGB32); frame.render(&image); @@ -877,6 +879,8 @@ void tst_QStyleSheetStyle::hoverColors() QTest::mouseMove (widget, QPoint(5,5)); QTest::qWait(60); + QVERIFY(widget->testAttribute(Qt::WA_UnderMouse)); + frame.render(&image); QVERIFY2(testForColors(image, QColor(0xe8, 0xff, 0x66)), -- cgit v0.12