summaryrefslogtreecommitdiffstats
path: root/tests/auto/qwidget/tst_qwidget.cpp
diff options
context:
space:
mode:
authorGareth Stockwell <ext-gareth.stockwell@nokia.com>2009-11-04 18:42:33 (GMT)
committerGareth Stockwell <ext-gareth.stockwell@nokia.com>2009-11-04 18:42:33 (GMT)
commiteda773316824cbb1aa7bdba402e568340b79b4f3 (patch)
treeb8dbd87ab3b1d8f9ef37f5fcaaa90dbd06883d81 /tests/auto/qwidget/tst_qwidget.cpp
parente3500ec7fb8c17c33345142a22eeef8e467564cd (diff)
downloadQt-eda773316824cbb1aa7bdba402e568340b79b4f3.zip
Qt-eda773316824cbb1aa7bdba402e568340b79b4f3.tar.gz
Qt-eda773316824cbb1aa7bdba402e568340b79b4f3.tar.bz2
tst_qwidget widgetAt now does not leave widget lowered if test fails
Task-number: QTBUG-5396 Reviewed-by: axis
Diffstat (limited to 'tests/auto/qwidget/tst_qwidget.cpp')
-rw-r--r--tests/auto/qwidget/tst_qwidget.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/auto/qwidget/tst_qwidget.cpp b/tests/auto/qwidget/tst_qwidget.cpp
index 3d801cc..e027dd1 100644
--- a/tests/auto/qwidget/tst_qwidget.cpp
+++ b/tests/auto/qwidget/tst_qwidget.cpp
@@ -3328,9 +3328,10 @@ void tst_QWidget::widgetAt()
w2->lower();
qApp->processEvents();
QTRY_VERIFY((wr = QApplication::widgetAt(100, 100)));
- QCOMPARE(wr->objectName(), QString("w1"));
-
+ const bool match = (wr->objectName() == QString("w1"));
w2->raise();
+ QVERIFY(match);
+
qApp->processEvents();
QTRY_VERIFY((wr = QApplication::widgetAt(100, 100)));
QCOMPARE(wr->objectName(), QString("w2"));