summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKari Oikarinen <kari.oikarinen@qt.io>2018-02-21 10:16:14 +0200
committerVille Voutilainen <ville.voutilainen@qt.io>2018-02-23 20:00:11 +0000
commit53d1e9ed21d25e65a2f13606af479838f5f21fe7 (patch)
treeb72d5a22d0f0c3a618b51b7b87cfdb45f2cca81b
parentfd85eaacd9221db3a900fc5ef1364b516ea75d69 (diff)
tests: Wrap qWaitForWindow{Active,Exposed} in QVERIFYv5.11.0-beta1
The functions are marked Q_REQUIRED_RESULT, so they give compilation warnings when not handling the bool return value. Failing the test early at an unexpected event is also better behavior anyway. Task-number: QTBUG-66559 Change-Id: I6c4db29379ec01528208c3e4ee54346b4230616c Reviewed-by: Sami Nurmenniemi <sami.nurmenniemi@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
-rw-r--r--tests/auto/quick/qquickanimatedimage/tst_qquickanimatedimage.cpp6
-rw-r--r--tests/auto/quick/qquickapplication/tst_qquickapplication.cpp4
-rw-r--r--tests/auto/quick/qquickborderimage/tst_qquickborderimage.cpp4
-rw-r--r--tests/auto/quick/qquickfocusscope/tst_qquickfocusscope.cpp12
-rw-r--r--tests/auto/quick/qquickframebufferobject/tst_qquickframebufferobject.cpp4
-rw-r--r--tests/auto/quick/qquickgridview/tst_qquickgridview.cpp4
-rw-r--r--tests/auto/quick/qquickitem/tst_qquickitem.cpp50
-rw-r--r--tests/auto/quick/qquickitem2/tst_qquickitem.cpp4
-rw-r--r--tests/auto/quick/qquickitemlayer/tst_qquickitemlayer.cpp6
-rw-r--r--tests/auto/quick/qquicklistview/tst_qquicklistview.cpp10
-rw-r--r--tests/auto/quick/qquickloader/tst_qquickloader.cpp4
-rw-r--r--tests/auto/quick/qquickmousearea/tst_qquickmousearea.cpp14
-rw-r--r--tests/auto/quick/qquickpositioners/tst_qquickpositioners.cpp6
-rw-r--r--tests/auto/quick/qquicktextedit/tst_qquicktextedit.cpp64
-rw-r--r--tests/auto/quick/qquicktextinput/tst_qquicktextinput.cpp92
-rw-r--r--tests/auto/quick/qquickwindow/tst_qquickwindow.cpp34
-rw-r--r--tests/auto/quick/scenegraph/tst_scenegraph.cpp8
-rw-r--r--tests/auto/quicktest/signalspy/tst_signalspy.cpp2
18 files changed, 164 insertions, 164 deletions
diff --git a/tests/auto/quick/qquickanimatedimage/tst_qquickanimatedimage.cpp b/tests/auto/quick/qquickanimatedimage/tst_qquickanimatedimage.cpp
index e303495944..077c8b422d 100644
--- a/tests/auto/quick/qquickanimatedimage/tst_qquickanimatedimage.cpp
+++ b/tests/auto/quick/qquickanimatedimage/tst_qquickanimatedimage.cpp
@@ -152,7 +152,7 @@ void tst_qquickanimatedimage::mirror_running()
QQuickView window;
window.setSource(testFileUrl("hearts.qml"));
window.show();
- QTest::qWaitForWindowExposed(&window);
+ QVERIFY(QTest::qWaitForWindowExposed(&window));
QQuickAnimatedImage *anim = qobject_cast<QQuickAnimatedImage *>(window.rootObject());
QVERIFY(anim);
@@ -565,8 +565,8 @@ void tst_qquickanimatedimage::noCaching()
window_nocache.setSource(testFileUrl("colors_nocache.qml"));
window.show();
window_nocache.show();
- QTest::qWaitForWindowExposed(&window);
- QTest::qWaitForWindowExposed(&window_nocache);
+ QVERIFY(QTest::qWaitForWindowExposed(&window));
+ QVERIFY(QTest::qWaitForWindowExposed(&window_nocache));
QQuickAnimatedImage *anim = qobject_cast<QQuickAnimatedImage *>(window.rootObject());
QVERIFY(anim);
diff --git a/tests/auto/quick/qquickapplication/tst_qquickapplication.cpp b/tests/auto/quick/qquickapplication/tst_qquickapplication.cpp
index 89b7924618..b681b4371f 100644
--- a/tests/auto/quick/qquickapplication/tst_qquickapplication.cpp
+++ b/tests/auto/quick/qquickapplication/tst_qquickapplication.cpp
@@ -95,7 +95,7 @@ void tst_qquickapplication::active()
// active
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QCOMPARE(QGuiApplication::focusWindow(), &window);
QVERIFY(item->property("active").toBool());
QVERIFY(item->property("active2").toBool());
@@ -165,7 +165,7 @@ void tst_qquickapplication::state()
// triggered by window activation.
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QCOMPARE(QGuiApplication::focusWindow(), &window);
QCOMPARE(Qt::ApplicationState(item->property("state").toInt()), Qt::ApplicationActive);
QCOMPARE(Qt::ApplicationState(item->property("state2").toInt()), Qt::ApplicationActive);
diff --git a/tests/auto/quick/qquickborderimage/tst_qquickborderimage.cpp b/tests/auto/quick/qquickborderimage/tst_qquickborderimage.cpp
index 71b0160c8e..c801077c75 100644
--- a/tests/auto/quick/qquickborderimage/tst_qquickborderimage.cpp
+++ b/tests/auto/quick/qquickborderimage/tst_qquickborderimage.cpp
@@ -248,7 +248,7 @@ void tst_qquickborderimage::mirror()
screenshot = window->grabWindow();
window->show();
- QTest::qWaitForWindowExposed(window);
+ QVERIFY(QTest::qWaitForWindowExposed(window));
if (window->rendererInterface()->graphicsApi() == QSGRendererInterface::Software)
QSKIP("QTBUG-53823");
QCOMPARE(screenshot, srcPixmap);
@@ -590,7 +590,7 @@ void tst_qquickborderimage::borderImageMesh()
window->setSource(testFileUrl("nonmesh.qml"));
window->show();
- QTest::qWaitForWindowExposed(window);
+ QVERIFY(QTest::qWaitForWindowExposed(window));
QImage nonmesh = window->grabWindow();
window->setSource(testFileUrl("mesh.qml"));
diff --git a/tests/auto/quick/qquickfocusscope/tst_qquickfocusscope.cpp b/tests/auto/quick/qquickfocusscope/tst_qquickfocusscope.cpp
index 5ac7fa7015..d1f5f8b8d6 100644
--- a/tests/auto/quick/qquickfocusscope/tst_qquickfocusscope.cpp
+++ b/tests/auto/quick/qquickfocusscope/tst_qquickfocusscope.cpp
@@ -75,7 +75,7 @@ void tst_qquickfocusscope::basic()
view->show();
view->requestActivate();
- QTest::qWaitForWindowActive(view);
+ QVERIFY(QTest::qWaitForWindowActive(view));
QTRY_COMPARE(view, qGuiApp->focusWindow());
QVERIFY(view->isTopLevel());
@@ -120,7 +120,7 @@ void tst_qquickfocusscope::nested()
view->show();
view->requestActivate();
- QTest::qWaitForWindowActive(view);
+ QVERIFY(QTest::qWaitForWindowActive(view));
QTRY_COMPARE(view, qGuiApp->focusWindow());
QVERIFY(item1->hasActiveFocus());
@@ -187,7 +187,7 @@ void tst_qquickfocusscope::textEdit()
view->show();
view->requestActivate();
- QTest::qWaitForWindowActive(view);
+ QVERIFY(QTest::qWaitForWindowActive(view));
QTRY_COMPARE(view, qGuiApp->focusWindow());
QVERIFY(item0->hasActiveFocus());
@@ -240,7 +240,7 @@ void tst_qquickfocusscope::forceFocus()
view->show();
view->requestActivate();
- QTest::qWaitForWindowActive(view);
+ QVERIFY(QTest::qWaitForWindowActive(view));
QTRY_COMPARE(view, qGuiApp->focusWindow());
QVERIFY(item0->hasActiveFocus());
@@ -277,7 +277,7 @@ void tst_qquickfocusscope::noParentFocus()
view->show();
view->requestActivate();
- QTest::qWaitForWindowActive(view);
+ QVERIFY(QTest::qWaitForWindowActive(view));
QTRY_COMPARE(view, qGuiApp->focusWindow());
QVERIFY(!view->rootObject()->property("focus1").toBool());
@@ -306,7 +306,7 @@ void tst_qquickfocusscope::signalEmission()
view->show();
view->requestActivate();
- QTest::qWaitForWindowActive(view);
+ QVERIFY(QTest::qWaitForWindowActive(view));
QTRY_COMPARE(view, qGuiApp->focusWindow());
QVariant blue(QColor("blue"));
diff --git a/tests/auto/quick/qquickframebufferobject/tst_qquickframebufferobject.cpp b/tests/auto/quick/qquickframebufferobject/tst_qquickframebufferobject.cpp
index 363064aa31..12e9794dc8 100644
--- a/tests/auto/quick/qquickframebufferobject/tst_qquickframebufferobject.cpp
+++ b/tests/auto/quick/qquickframebufferobject/tst_qquickframebufferobject.cpp
@@ -193,7 +193,7 @@ void tst_QQuickFramebufferObject::testThatStuffWorks()
view.show();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QImage result = view.grabWindow();
@@ -233,7 +233,7 @@ void tst_QQuickFramebufferObject::testInvalidate()
view.show();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QCOMPARE(frameInfo.fboSize, QSize(200, 200));
diff --git a/tests/auto/quick/qquickgridview/tst_qquickgridview.cpp b/tests/auto/quick/qquickgridview/tst_qquickgridview.cpp
index 58c9ffce71..fea90e9284 100644
--- a/tests/auto/quick/qquickgridview/tst_qquickgridview.cpp
+++ b/tests/auto/quick/qquickgridview/tst_qquickgridview.cpp
@@ -1974,7 +1974,7 @@ void tst_QQuickGridView::keyNavigation()
window->rootContext()->setContextProperty("testModel", &model);
window->setSource(testFileUrl("gridview1.qml"));
window->show();
- QTest::qWaitForWindowActive(window);
+ QVERIFY(QTest::qWaitForWindowActive(window));
QQuickGridView *gridview = findItem<QQuickGridView>(window->rootObject(), "grid");
QTRY_VERIFY(gridview != 0);
@@ -1984,7 +1984,7 @@ void tst_QQuickGridView::keyNavigation()
QTRY_COMPARE(QQuickItemPrivate::get(gridview)->polishScheduled, false);
window->requestActivate();
- QTest::qWaitForWindowActive(window);
+ QVERIFY(QTest::qWaitForWindowActive(window));
QTRY_COMPARE(qGuiApp->focusWindow(), window);
QCOMPARE(gridview->currentIndex(), 0);
diff --git a/tests/auto/quick/qquickitem/tst_qquickitem.cpp b/tests/auto/quick/qquickitem/tst_qquickitem.cpp
index f5e8c6858a..c2ae667d2b 100644
--- a/tests/auto/quick/qquickitem/tst_qquickitem.cpp
+++ b/tests/auto/quick/qquickitem/tst_qquickitem.cpp
@@ -203,12 +203,12 @@ private:
NoOp, Append, Remove, StackBefore, StackAfter, SetZ
};
- void ensureFocus(QWindow *w) {
+ bool ensureFocus(QWindow *w) {
if (w->width() <=0 || w->height() <= 0)
w->setGeometry(100, 100, 400, 300);
w->show();
w->requestActivate();
- QTest::qWaitForWindowActive(w);
+ return QTest::qWaitForWindowActive(w);
}
};
@@ -299,7 +299,7 @@ struct FocusState : public QHash<QQuickItem *, FocusData>
void tst_qquickitem::simpleFocus()
{
QQuickWindow window;
- ensureFocus(&window);
+ QVERIFY(ensureFocus(&window));
QTRY_COMPARE(QGuiApplication::focusWindow(), &window);
@@ -351,7 +351,7 @@ void tst_qquickitem::simpleFocus()
void tst_qquickitem::scopedFocus()
{
QQuickWindow window;
- ensureFocus(&window);
+ QVERIFY(ensureFocus(&window));
QTRY_COMPARE(QGuiApplication::focusWindow(), &window);
QQuickItem *l1c1 = new TestItem(window.contentItem());
@@ -431,7 +431,7 @@ void tst_qquickitem::addedToWindow()
{
{
QQuickWindow window;
- ensureFocus(&window);
+ QVERIFY(ensureFocus(&window));
QTRY_COMPARE(QGuiApplication::focusWindow(), &window);
QQuickItem *item = new TestItem;
@@ -451,7 +451,7 @@ void tst_qquickitem::addedToWindow()
{
QQuickWindow window;
- ensureFocus(&window);
+ QVERIFY(ensureFocus(&window));
QTRY_COMPARE(QGuiApplication::focusWindow(), &window);
QQuickItem *item = new TestItem(window.contentItem());
@@ -480,7 +480,7 @@ void tst_qquickitem::addedToWindow()
{
QQuickWindow window;
- ensureFocus(&window);
+ QVERIFY(ensureFocus(&window));
QTRY_COMPARE(QGuiApplication::focusWindow(), &window);
QQuickItem *tree = new TestItem;
@@ -504,7 +504,7 @@ void tst_qquickitem::addedToWindow()
{
QQuickWindow window;
- ensureFocus(&window);
+ QVERIFY(ensureFocus(&window));
QTRY_COMPARE(QGuiApplication::focusWindow(), &window);
QQuickItem *tree = new TestFocusScope;
QQuickItem *c1 = new TestItem(tree);
@@ -532,7 +532,7 @@ void tst_qquickitem::addedToWindow()
{
QQuickWindow window;
- ensureFocus(&window);
+ QVERIFY(ensureFocus(&window));
QTRY_COMPARE(QGuiApplication::focusWindow(), &window);
QQuickItem *tree = new TestFocusScope;
QQuickItem *c1 = new TestItem(tree);
@@ -558,7 +558,7 @@ void tst_qquickitem::addedToWindow()
{
QQuickWindow window;
- ensureFocus(&window);
+ QVERIFY(ensureFocus(&window));
QTRY_COMPARE(QGuiApplication::focusWindow(), &window);
QQuickItem *child = new TestItem(window.contentItem());
QQuickItem *tree = new TestFocusScope;
@@ -598,7 +598,7 @@ void tst_qquickitem::changeParent()
// Parent to no parent
{
QQuickWindow window;
- ensureFocus(&window);
+ QVERIFY(ensureFocus(&window));
QTRY_COMPARE(QGuiApplication::focusWindow(), &window);
QQuickItem *child = new TestItem(window.contentItem());
@@ -620,7 +620,7 @@ void tst_qquickitem::changeParent()
// Different parent, same focus scope
{
QQuickWindow window;
- ensureFocus(&window);
+ QVERIFY(ensureFocus(&window));
QTRY_COMPARE(QGuiApplication::focusWindow(), &window);
QQuickItem *child = new TestItem(window.contentItem());
QQuickItem *child2 = new TestItem(window.contentItem());
@@ -641,7 +641,7 @@ void tst_qquickitem::changeParent()
// Different parent, different focus scope
{
QQuickWindow window;
- ensureFocus(&window);
+ QVERIFY(ensureFocus(&window));
QTRY_COMPARE(QGuiApplication::focusWindow(), &window);
QQuickItem *child = new TestItem(window.contentItem());
QQuickItem *child2 = new TestFocusScope(window.contentItem());
@@ -663,7 +663,7 @@ void tst_qquickitem::changeParent()
}
{
QQuickWindow window;
- ensureFocus(&window);
+ QVERIFY(ensureFocus(&window));
QTRY_COMPARE(QGuiApplication::focusWindow(), &window);
QQuickItem *child = new TestItem(window.contentItem());
QQuickItem *child2 = new TestFocusScope(window.contentItem());
@@ -685,7 +685,7 @@ void tst_qquickitem::changeParent()
}
{
QQuickWindow window;
- ensureFocus(&window);
+ QVERIFY(ensureFocus(&window));
QTRY_COMPARE(QGuiApplication::focusWindow(), &window);
QQuickItem *child = new TestItem(window.contentItem());
QQuickItem *child2 = new TestFocusScope(window.contentItem());
@@ -711,7 +711,7 @@ void tst_qquickitem::changeParent()
// child is deleted, then its parent changes again to a valid parent
{
QQuickWindow window;
- ensureFocus(&window);
+ QVERIFY(ensureFocus(&window));
QTRY_COMPARE(QGuiApplication::focusWindow(), &window);
QQuickItem *item = new TestFocusScope(window.contentItem());
QQuickItem *child = new TestItem(item);
@@ -750,7 +750,7 @@ void tst_qquickitem::multipleFocusClears()
QQuickView view;
view.setSource(testFileUrl("multipleFocusClears.qml"));
view.show();
- ensureFocus(&view);
+ QVERIFY(ensureFocus(&view));
QTRY_COMPARE(QGuiApplication::focusWindow(), &view);
}
@@ -759,7 +759,7 @@ void tst_qquickitem::focusSubItemInNonFocusScope()
QQuickView view;
view.setSource(testFileUrl("focusSubItemInNonFocusScope.qml"));
view.show();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QQuickItem *dummyItem = view.rootObject()->findChild<QQuickItem *>("dummyItem");
QVERIFY(dummyItem);
@@ -781,7 +781,7 @@ void tst_qquickitem::focusSubItemInNonFocusScope()
void tst_qquickitem::parentItemWithFocus()
{
QQuickWindow window;
- ensureFocus(&window);
+ QVERIFY(ensureFocus(&window));
QTRY_COMPARE(QGuiApplication::focusWindow(), &window);
{
QQuickItem parent;
@@ -880,7 +880,7 @@ void tst_qquickitem::parentItemWithFocus()
void tst_qquickitem::reparentFocusedItem()
{
QQuickWindow window;
- ensureFocus(&window);
+ QVERIFY(ensureFocus(&window));
QTRY_COMPARE(QGuiApplication::focusWindow(), &window);
QQuickItem parent(window.contentItem());
@@ -1047,7 +1047,7 @@ void tst_qquickitem::enabled()
void tst_qquickitem::enabledFocus()
{
QQuickWindow window;
- ensureFocus(&window);
+ QVERIFY(ensureFocus(&window));
QQuickFocusScope root;
@@ -1308,7 +1308,7 @@ void tst_qquickitem::touchEventAcceptIgnore()
TestWindow window;
window.resize(100, 100);
window.show();
- QTest::qWaitForWindowExposed(&window);
+ QVERIFY(QTest::qWaitForWindowExposed(&window));
QScopedPointer<TestItem> item(new TestItem);
item->setSize(QSizeF(100, 100));
@@ -1419,7 +1419,7 @@ void tst_qquickitem::polishOnCompleted()
QQuickView view;
view.setSource(testFileUrl("polishOnCompleted.qml"));
view.show();
- QTest::qWaitForWindowExposed(&view);
+ QVERIFY(QTest::qWaitForWindowExposed(&view));
TestPolishItem *item = qobject_cast<TestPolishItem*>(view.rootObject());
QVERIFY(item);
@@ -1451,7 +1451,7 @@ void tst_qquickitem::wheelEvent()
QQuickWindow window;
window.resize(width, height);
window.show();
- QTest::qWaitForWindowExposed(&window);
+ QVERIFY(QTest::qWaitForWindowExposed(&window));
TestItem *item = new TestItem;
item->setSize(QSizeF(width, height));
@@ -2072,7 +2072,7 @@ void tst_qquickitem::shortcutOverride()
{
QQuickView view;
view.setSource(testFileUrl("shortcutOverride.qml"));
- ensureFocus(&view);
+ QVERIFY(ensureFocus(&view));
QCOMPARE(view.rootObject()->property("escapeHandlerActivationCount").toInt(), 0);
QCOMPARE(view.rootObject()->property("shortcutActivationCount").toInt(), 0);
diff --git a/tests/auto/quick/qquickitem2/tst_qquickitem.cpp b/tests/auto/quick/qquickitem2/tst_qquickitem.cpp
index b66dc1708f..af4ee41824 100644
--- a/tests/auto/quick/qquickitem2/tst_qquickitem.cpp
+++ b/tests/auto/quick/qquickitem2/tst_qquickitem.cpp
@@ -2811,7 +2811,7 @@ void tst_QQuickItem::changeListener()
{
QQuickWindow window;
window.show();
- QTest::qWaitForWindowExposed(&window);
+ QVERIFY(QTest::qWaitForWindowExposed(&window));
QQuickItem *item = new QQuickItem;
TestListener itemListener;
@@ -3312,7 +3312,7 @@ void tst_QQuickItem::grab()
QQuickView view;
view.setSource(testFileUrl("grabToImage.qml"));
view.show();
- QTest::qWaitForWindowExposed(&view);
+ QVERIFY(QTest::qWaitForWindowExposed(&view));
QQuickItem *root = qobject_cast<QQuickItem *>(view.rootObject());
QVERIFY(root);
diff --git a/tests/auto/quick/qquickitemlayer/tst_qquickitemlayer.cpp b/tests/auto/quick/qquickitemlayer/tst_qquickitemlayer.cpp
index a8a00b51e9..599e8d92b4 100644
--- a/tests/auto/quick/qquickitemlayer/tst_qquickitemlayer.cpp
+++ b/tests/auto/quick/qquickitemlayer/tst_qquickitemlayer.cpp
@@ -139,7 +139,7 @@ void tst_QQuickItemLayer::initTestCase()
#endif
QQuickView view;
view.showNormal();
- QTest::qWaitForWindowExposed(&view);
+ QVERIFY(QTest::qWaitForWindowExposed(&view));
if (view.rendererInterface()->graphicsApi() != QSGRendererInterface::OpenGL)
m_isOpenGLRenderer = false;
}
@@ -307,7 +307,7 @@ void tst_QQuickItemLayer::layerVisibility()
view.show();
- QTest::qWaitForWindowExposed(&view);
+ QVERIFY(QTest::qWaitForWindowExposed(&view));
QImage fb = view.grabWindow();
uint pixel = fb.pixel(0, 0);
@@ -513,7 +513,7 @@ void tst_QQuickItemLayer::textureMirroring()
view.show();
- QTest::qWaitForWindowExposed(&view);
+ QVERIFY(QTest::qWaitForWindowExposed(&view));
QImage fb = view.grabWindow();
diff --git a/tests/auto/quick/qquicklistview/tst_qquicklistview.cpp b/tests/auto/quick/qquicklistview/tst_qquicklistview.cpp
index dc8c727cbe..8118cf615a 100644
--- a/tests/auto/quick/qquicklistview/tst_qquicklistview.cpp
+++ b/tests/auto/quick/qquicklistview/tst_qquicklistview.cpp
@@ -2282,7 +2282,7 @@ void tst_QQuickListView::sectionsDelegate_headerVisibility()
window->show();
QVERIFY(QTest::qWaitForWindowExposed(window.data()));
window->requestActivate();
- QTest::qWaitForWindowActive(window.data());
+ QVERIFY(QTest::qWaitForWindowActive(window.data()));
QQuickListView *listview = findItem<QQuickListView>(window->rootObject(), "list");
QTRY_VERIFY(listview != 0);
@@ -2826,7 +2826,7 @@ void tst_QQuickListView::keyNavigation()
window->rootContext()->setContextProperty("testObject", testObject);
window->setSource(testFileUrl("listviewtest.qml"));
window->show();
- QTest::qWaitForWindowActive(window);
+ QVERIFY(QTest::qWaitForWindowActive(window));
QQuickListView *listview = findItem<QQuickListView>(window->rootObject(), "list");
QTRY_VERIFY(listview != 0);
@@ -2837,7 +2837,7 @@ void tst_QQuickListView::keyNavigation()
QTRY_COMPARE(QQuickItemPrivate::get(listview)->polishScheduled, false);
window->requestActivate();
- QTest::qWaitForWindowActive(window);
+ QVERIFY(QTest::qWaitForWindowActive(window));
QTRY_COMPARE(qGuiApp->focusWindow(), window);
QTest::keyClick(window, forwardsKey);
@@ -7264,7 +7264,7 @@ void tst_QQuickListView::parentBinding()
window->setSource(testFileUrl("parentBinding.qml"));
window->show();
- QTest::qWaitForWindowExposed(window.data());
+ QVERIFY(QTest::qWaitForWindowExposed(window.data()));
QQuickListView *listview = qobject_cast<QQuickListView*>(window->rootObject());
QVERIFY(listview != 0);
@@ -8643,7 +8643,7 @@ void tst_QQuickListView::itemFiltered()
window->setContent(QUrl(), &component, component.create());
window->show();
- QTest::qWaitForWindowExposed(window.data());
+ QVERIFY(QTest::qWaitForWindowExposed(window.data()));
// this should not crash
model.setData(model.index(2), QStringLiteral("modified three"), Qt::DisplayRole);
diff --git a/tests/auto/quick/qquickloader/tst_qquickloader.cpp b/tests/auto/quick/qquickloader/tst_qquickloader.cpp
index 65493f52e2..613d500746 100644
--- a/tests/auto/quick/qquickloader/tst_qquickloader.cpp
+++ b/tests/auto/quick/qquickloader/tst_qquickloader.cpp
@@ -1188,7 +1188,7 @@ void tst_QQuickLoader::transientWindow() // QTBUG-52944
timer.start();
view.show();
- QTest::qWaitForWindowExposed(&view);
+ QVERIFY(QTest::qWaitForWindowExposed(&view));
QTRY_VERIFY(loadedWindowVisibleTime >= 0);
QVERIFY(viewVisibleTime >= 0);
@@ -1229,7 +1229,7 @@ void tst_QQuickLoader::nestedTransientWindow() // QTBUG-52944
timer.start();
view.show();
- QTest::qWaitForWindowExposed(&view);
+ QVERIFY(QTest::qWaitForWindowExposed(&view));
QTRY_VERIFY(loadedWindowVisibleTime >= 0);
QVERIFY(viewVisibleTime >= 0);
diff --git a/tests/auto/quick/qquickmousearea/tst_qquickmousearea.cpp b/tests/auto/quick/qquickmousearea/tst_qquickmousearea.cpp
index 4fe01787fa..76038d013b 100644
--- a/tests/auto/quick/qquickmousearea/tst_qquickmousearea.cpp
+++ b/tests/auto/quick/qquickmousearea/tst_qquickmousearea.cpp
@@ -219,7 +219,7 @@ void tst_QQuickMouseArea::dragProperties()
QByteArray errorMessage;
QVERIFY2(initView(window, testFileUrl("dragproperties.qml"), true, &errorMessage), errorMessage.constData());
window.show();
- QTest::qWaitForWindowExposed(&window);
+ QVERIFY(QTest::qWaitForWindowExposed(&window));
QVERIFY(window.rootObject() != 0);
QQuickMouseArea *mouseRegion = window.rootObject()->findChild<QQuickMouseArea*>("mouseregion");
@@ -317,7 +317,7 @@ void tst_QQuickMouseArea::resetDrag()
window.rootContext()->setContextProperty("haveTarget", QVariant(true));
QVERIFY2(initView(window, testFileUrl("dragreset.qml"), true, &errorMessage), errorMessage.constData());
window.show();
- QTest::qWaitForWindowExposed(&window);
+ QVERIFY(QTest::qWaitForWindowExposed(&window));
QVERIFY(window.rootObject() != 0);
QQuickMouseArea *mouseRegion = window.rootObject()->findChild<QQuickMouseArea*>("mouseregion");
@@ -524,7 +524,7 @@ void tst_QQuickMouseArea::invalidDrag()
QByteArray errorMessage;
QVERIFY2(initView(window, testFileUrl("dragging.qml"), true, &errorMessage), errorMessage.constData());
window.show();
- QTest::qWaitForWindowExposed(&window);
+ QVERIFY(QTest::qWaitForWindowExposed(&window));
QVERIFY(window.rootObject() != 0);
QQuickMouseArea *mouseRegion = window.rootObject()->findChild<QQuickMouseArea*>("mouseregion");
@@ -656,7 +656,7 @@ void tst_QQuickMouseArea::setDragOnPressed()
QByteArray errorMessage;
QVERIFY2(initView(window, testFileUrl("setDragOnPressed.qml"), true, &errorMessage), errorMessage.constData());
window.show();
- QTest::qWaitForWindowExposed(&window);
+ QVERIFY(QTest::qWaitForWindowExposed(&window));
QVERIFY(window.rootObject() != 0);
QQuickMouseArea *mouseArea = qobject_cast<QQuickMouseArea *>(window.rootObject());
@@ -908,7 +908,7 @@ void tst_QQuickMouseArea::pressedCanceledOnWindowDeactivate()
QWindow *secondWindow = qvariant_cast<QWindow*>(window.rootObject()->property("secondWindow"));
secondWindow->setProperty("visible", true);
- QTest::qWaitForWindowExposed(secondWindow);
+ QVERIFY(QTest::qWaitForWindowExposed(secondWindow));
QTRY_VERIFY(!window.rootObject()->property("pressed").toBool());
QVERIFY(window.rootObject()->property("canceled").toBool());
@@ -1671,7 +1671,7 @@ void tst_QQuickMouseArea::pressedMultipleButtons()
QByteArray errorMessage;
QVERIFY2(initView(view, testFileUrl("simple.qml"), true, &errorMessage), errorMessage.constData());
view.show();
- QTest::qWaitForWindowExposed(&view);
+ QVERIFY(QTest::qWaitForWindowExposed(&view));
QVERIFY(view.rootObject() != 0);
QQuickMouseArea *mouseArea = view.rootObject()->findChild<QQuickMouseArea *>("mousearea");
@@ -2157,7 +2157,7 @@ void tst_QQuickMouseArea::notPressedAfterStolenGrab()
QQuickWindow window;
window.resize(200, 200);
window.show();
- QTest::qWaitForWindowExposed(&window);
+ QVERIFY(QTest::qWaitForWindowExposed(&window));
QQuickMouseArea *ma = new QQuickMouseArea(window.contentItem());
ma->setSize(window.size());
diff --git a/tests/auto/quick/qquickpositioners/tst_qquickpositioners.cpp b/tests/auto/quick/qquickpositioners/tst_qquickpositioners.cpp
index 1b3939401a..25e34b980b 100644
--- a/tests/auto/quick/qquickpositioners/tst_qquickpositioners.cpp
+++ b/tests/auto/quick/qquickpositioners/tst_qquickpositioners.cpp
@@ -1037,7 +1037,7 @@ void tst_qquickpositioners::populateTransitions(const QString &positionerObjectN
QQuickItem *positioner = window->rootObject()->findChild<QQuickItem*>(positionerObjectName);
QVERIFY(positioner);
window->show();
- QTest::qWaitForWindowExposed(window.data());
+ QVERIFY(QTest::qWaitForWindowExposed(window.data()));
qApp->processEvents();
if (!dynamicallyPopulate && usePopulateTransition) {
@@ -1120,7 +1120,7 @@ void tst_qquickpositioners::addTransitions(const QString &positionerObjectName)
ctxt->setContextProperty("testedPositioner", QString());
window->setSource(testFileUrl(qmlFile));
window->show();
- QTest::qWaitForWindowExposed(window.data());
+ QVERIFY(QTest::qWaitForWindowExposed(window.data()));
qApp->processEvents();
QQuickItem *positioner = window->rootObject()->findChild<QQuickItem*>(positionerObjectName);
@@ -1243,7 +1243,7 @@ void tst_qquickpositioners::moveTransitions(const QString &positionerObjectName)
ctxt->setContextProperty("testedPositioner", QString());
window->setSource(testFileUrl(qmlFile));
window->show();
- QTest::qWaitForWindowExposed(window.data());
+ QVERIFY(QTest::qWaitForWindowExposed(window.data()));
qApp->processEvents();
QList<QPair<QString,QString> > expectedDisplacedValues = expectedDisplacedIndexes.getModelDataValues(model);
diff --git a/tests/auto/quick/qquicktextedit/tst_qquicktextedit.cpp b/tests/auto/quick/qquicktextedit/tst_qquicktextedit.cpp
index d0031e397b..37f6e94271 100644
--- a/tests/auto/quick/qquicktextedit/tst_qquicktextedit.cpp
+++ b/tests/auto/quick/qquicktextedit/tst_qquicktextedit.cpp
@@ -790,7 +790,7 @@ void tst_qquicktextedit::hAlign_RightToLeft()
QVERIFY(textEdit->positionToRectangle(0).x() < window.width()/2);
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(textEdit->hasActiveFocus());
textEdit->setText(QString());
@@ -1224,7 +1224,7 @@ void tst_qquicktextedit::persistentSelection()
QQuickView window(testFileUrl("persistentSelection.qml"));
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QQuickTextEdit *edit = qobject_cast<QQuickTextEdit *>(window.rootObject());
QVERIFY(edit);
@@ -1267,7 +1267,7 @@ void tst_qquicktextedit::selectionOnFocusOut()
QQuickView window(testFileUrl("focusOutSelection.qml"));
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QPoint p1(25, 35);
QPoint p2(25, 85);
@@ -1335,7 +1335,7 @@ void tst_qquicktextedit::focusOnPress()
textEditObject->setParentItem(window.contentItem());
window.showNormal();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QCOMPARE(textEditObject->hasFocus(), false);
QCOMPARE(textEditObject->hasActiveFocus(), false);
@@ -1487,7 +1487,7 @@ void tst_qquicktextedit::overwriteMode()
textEdit->setParentItem(window.contentItem());
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(textEdit->hasActiveFocus());
@@ -1603,7 +1603,7 @@ void tst_qquicktextedit::keySelection()
QQuickView window(testFileUrl("navigation.qml"));
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(window.rootObject() != 0);
@@ -2060,7 +2060,7 @@ void tst_qquicktextedit::mouseSelection()
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(window.rootObject() != 0);
QQuickTextEdit *textEditObject = qobject_cast<QQuickTextEdit *>(window.rootObject());
@@ -2107,7 +2107,7 @@ void tst_qquicktextedit::dragMouseSelection()
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(window.rootObject() != 0);
QQuickTextEdit *textEditObject = qobject_cast<QQuickTextEdit *>(window.rootObject());
@@ -2160,7 +2160,7 @@ void tst_qquicktextedit::mouseSelectionMode()
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(window.rootObject() != 0);
QQuickTextEdit *textEditObject = qobject_cast<QQuickTextEdit *>(window.rootObject());
@@ -2345,7 +2345,7 @@ void tst_qquicktextedit::keyboardSelection()
edit->setParentItem(window.contentItem());
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(edit->hasActiveFocus());
simulateKeys(&window, standardKey);
@@ -2422,7 +2422,7 @@ void tst_qquicktextedit::positionAt()
QVERIFY(window.rootObject() != 0);
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QQuickTextEdit *texteditObject = qobject_cast<QQuickTextEdit *>(window.rootObject());
QVERIFY(texteditObject != 0);
@@ -2512,7 +2512,7 @@ void tst_qquicktextedit::linkInteraction()
QVERIFY(window.rootObject() != 0);
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QQuickTextEdit *texteditObject = qobject_cast<QQuickTextEdit *>(window.rootObject());
QVERIFY(texteditObject != 0);
@@ -2572,7 +2572,7 @@ void tst_qquicktextedit::cursorDelegate()
QQuickView view(source);
view.show();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QQuickTextEdit *textEditObject = view.rootObject()->findChild<QQuickTextEdit*>("textEditObject");
QVERIFY(textEditObject != 0);
// Delegate creation is deferred until focus in or cursor visibility is forced.
@@ -2687,7 +2687,7 @@ void tst_qquicktextedit::remoteCursorDelegate()
view.setSource(testFileUrl("cursorTestRemote.qml"));
view.showNormal();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QQuickTextEdit *textEditObject = view.rootObject()->findChild<QQuickTextEdit*>("textEditObject");
QVERIFY(textEditObject != 0);
@@ -2713,7 +2713,7 @@ void tst_qquicktextedit::cursorVisible()
QQuickView view(testFileUrl("cursorVisible.qml"));
view.show();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QCOMPARE(&view, qGuiApp->focusWindow());
QCOMPARE(edit.isCursorVisible(), false);
@@ -2745,13 +2745,13 @@ void tst_qquicktextedit::cursorVisible()
QWindow alternateView;
alternateView.show();
alternateView.requestActivate();
- QTest::qWaitForWindowActive(&alternateView);
+ QVERIFY(QTest::qWaitForWindowActive(&alternateView));
QCOMPARE(edit.isCursorVisible(), false);
QCOMPARE(spy.count(), 6);
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QCOMPARE(edit.isCursorVisible(), true);
QCOMPARE(spy.count(), 7);
@@ -2858,7 +2858,7 @@ void tst_qquicktextedit::cursorDelegateHeight()
QQuickView view(testFileUrl("cursorHeight.qml"));
view.show();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QQuickTextEdit *textEditObject = view.rootObject()->findChild<QQuickTextEdit*>("textEditObject");
QVERIFY(textEditObject);
// Delegate creation is deferred until focus in or cursor visibility is forced.
@@ -3051,7 +3051,7 @@ void tst_qquicktextedit::middleClickPaste()
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(window.rootObject() != 0);
QQuickTextEdit *textEditObject = qobject_cast<QQuickTextEdit *>(window.rootObject());
@@ -3122,7 +3122,7 @@ void tst_qquicktextedit::textInput()
QQuickView view(testFileUrl("inputMethodEvent.qml"));
view.show();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QQuickTextEdit *edit = qobject_cast<QQuickTextEdit *>(view.rootObject());
QVERIFY(edit);
QVERIFY(edit->hasActiveFocus());
@@ -3175,7 +3175,7 @@ void tst_qquicktextedit::inputMethodUpdate()
QQuickView view(testFileUrl("inputMethodEvent.qml"));
view.show();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QQuickTextEdit *edit = qobject_cast<QQuickTextEdit *>(view.rootObject());
QVERIFY(edit);
QVERIFY(edit->hasActiveFocus());
@@ -3265,7 +3265,7 @@ void tst_qquicktextedit::openInputPanel()
QQuickView view(testFileUrl("openInputPanel.qml"));
view.showNormal();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QQuickTextEdit *edit = qobject_cast<QQuickTextEdit *>(view.rootObject());
QVERIFY(edit);
@@ -3663,7 +3663,7 @@ void tst_qquicktextedit::preeditCursorRectangle()
QQuickView view(testFileUrl("inputMethodEvent.qml"));
view.show();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QQuickTextEdit *edit = qobject_cast<QQuickTextEdit *>(view.rootObject());
QVERIFY(edit);
@@ -3746,7 +3746,7 @@ void tst_qquicktextedit::inputMethodComposing()
QQuickView view(testFileUrl("inputContext.qml"));
view.show();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QQuickTextEdit *edit = qobject_cast<QQuickTextEdit *>(view.rootObject());
QVERIFY(edit);
@@ -3877,7 +3877,7 @@ void tst_qquicktextedit::cursorRectangleSize()
textEdit->setFocus(true);
window->show();
window->requestActivate();
- QTest::qWaitForWindowActive(window);
+ QVERIFY(QTest::qWaitForWindowActive(window));
QInputMethodQueryEvent event(Qt::ImCursorRectangle);
qApp->sendEvent(textEdit, &event);
@@ -4882,7 +4882,7 @@ void tst_qquicktextedit::keySequence()
textEdit->setParentItem(window.contentItem());
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(textEdit->hasActiveFocus());
@@ -5044,7 +5044,7 @@ void tst_qquicktextedit::undo()
textEdit->setParentItem(window.contentItem());
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(textEdit->hasActiveFocus());
QVERIFY(!textEdit->canUndo());
@@ -5130,7 +5130,7 @@ void tst_qquicktextedit::redo()
textEdit->setParentItem(window.contentItem());
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(textEdit->hasActiveFocus());
QVERIFY(!textEdit->canUndo());
@@ -5351,7 +5351,7 @@ void tst_qquicktextedit::undo_keypressevents()
textEdit->setParentItem(window.contentItem());
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(textEdit->hasActiveFocus());
simulateKeys(&window, keys);
@@ -5375,7 +5375,7 @@ void tst_qquicktextedit::clear()
textEdit->setParentItem(window.contentItem());
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(textEdit->hasActiveFocus());
QSignalSpy spy(textEdit, SIGNAL(canUndoChanged()));
@@ -5511,7 +5511,7 @@ void tst_qquicktextedit::emptytags_QTBUG_22058()
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QQuickTextEdit *input = qobject_cast<QQuickTextEdit *>(qvariant_cast<QObject *>(window.rootObject()->property("inputField")));
QVERIFY(input->hasActiveFocus());
@@ -5530,7 +5530,7 @@ void tst_qquicktextedit::cursorRectangle_QTBUG_38947()
window.show();
window.requestActivate();
- QTest::qWaitForWindowExposed(&window);
+ QVERIFY(QTest::qWaitForWindowExposed(&window));
QQuickTextEdit *edit = window.rootObject()->findChild<QQuickTextEdit *>("textedit");
QVERIFY(edit);
diff --git a/tests/auto/quick/qquicktextinput/tst_qquicktextinput.cpp b/tests/auto/quick/qquicktextinput/tst_qquicktextinput.cpp
index 06b76d129c..84a87f63a7 100644
--- a/tests/auto/quick/qquicktextinput/tst_qquicktextinput.cpp
+++ b/tests/auto/quick/qquicktextinput/tst_qquicktextinput.cpp
@@ -750,7 +750,7 @@ void tst_qquicktextinput::persistentSelection()
QQuickView window(testFileUrl("persistentSelection.qml"));
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QQuickTextInput *input = qobject_cast<QQuickTextInput *>(window.rootObject());
QVERIFY(input);
@@ -801,7 +801,7 @@ void tst_qquicktextinput::overwriteMode()
textInput->setParentItem(window.contentItem());
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(textInput->hasActiveFocus());
@@ -1304,7 +1304,7 @@ void tst_qquicktextinput::dragMouseSelection()
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(window.rootObject() != 0);
QQuickTextInput *textInputObject = qobject_cast<QQuickTextInput *>(window.rootObject());
@@ -1365,7 +1365,7 @@ void tst_qquicktextinput::mouseSelectionMode()
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(window.rootObject() != 0);
QQuickTextInput *textInputObject = qobject_cast<QQuickTextInput *>(window.rootObject());
@@ -1545,7 +1545,7 @@ void tst_qquicktextinput::horizontalAlignment_RightToLeft()
QCOMPARE(textInput->boundingRect().left(), qreal(0));
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(textInput->hasActiveFocus());
// If there is no committed text, the preedit text should determine the alignment.
@@ -1808,7 +1808,7 @@ void tst_qquicktextinput::positionAt()
QVERIFY(window.rootObject() != 0);
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QQuickTextInput *textinputObject = qobject_cast<QQuickTextInput *>(window.rootObject());
QVERIFY(textinputObject != 0);
@@ -1898,7 +1898,7 @@ void tst_qquicktextinput::maxLength()
QVERIFY(window.rootObject() != 0);
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QQuickTextInput *textinputObject = qobject_cast<QQuickTextInput *>(window.rootObject());
QVERIFY(textinputObject != 0);
@@ -1957,7 +1957,7 @@ void tst_qquicktextinput::validators()
QQuickView window(testFileUrl("validators.qml"));
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(window.rootObject() != 0);
@@ -2247,7 +2247,7 @@ void tst_qquicktextinput::inputMethods()
QQuickView window(testFileUrl("inputmethods.qml"));
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
// test input method hints
QVERIFY(window.rootObject() != 0);
@@ -2339,7 +2339,7 @@ void tst_qquicktextinput::signal_accepted()
QQuickView window(testFileUrl("signal_accepted.qml"));
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(window.rootObject() != 0);
@@ -2381,7 +2381,7 @@ void tst_qquicktextinput::signal_editingfinished()
QQuickView window(testFileUrl("signal_editingfinished.qml"));
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(window.rootObject() != 0);
@@ -2451,7 +2451,7 @@ void tst_qquicktextinput::signal_textEdited()
QQuickWindow window;
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QQuickTextInput *input = new QQuickTextInput(window.contentItem());
QVERIFY(input);
@@ -2702,7 +2702,7 @@ void tst_qquicktextinput::copyAndPasteKeySequence()
textInput->setParentItem(window.contentItem());
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
// copy and paste
QVERIFY(textInput->hasActiveFocus());
@@ -2796,7 +2796,7 @@ void tst_qquicktextinput::middleClickPaste()
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(window.rootObject() != 0);
QQuickTextInput *textInputObject = qobject_cast<QQuickTextInput *>(window.rootObject());
@@ -2861,7 +2861,7 @@ void tst_qquicktextinput::cursorDelegate()
QQuickView view(source);
view.show();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QQuickTextInput *textInputObject = view.rootObject()->findChild<QQuickTextInput*>("textInputObject");
QVERIFY(textInputObject != 0);
// Delegate is created on demand, and so won't be available immediately. Focus in or
@@ -2979,7 +2979,7 @@ void tst_qquicktextinput::remoteCursorDelegate()
view.setSource(testFileUrl("cursorTestRemote.qml"));
view.show();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QQuickTextInput *textInputObject = view.rootObject()->findChild<QQuickTextInput*>("textInputObject");
QVERIFY(textInputObject != 0);
@@ -3006,7 +3006,7 @@ void tst_qquicktextinput::cursorVisible()
QQuickView view(testFileUrl("cursorVisible.qml"));
view.show();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QCOMPARE(input.isCursorVisible(), false);
@@ -3037,13 +3037,13 @@ void tst_qquicktextinput::cursorVisible()
QQuickView alternateView;
alternateView.show();
alternateView.requestActivate();
- QTest::qWaitForWindowActive(&alternateView);
+ QVERIFY(QTest::qWaitForWindowActive(&alternateView));
QCOMPARE(input.isCursorVisible(), false);
QCOMPARE(spy.count(), 6);
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QCOMPARE(input.isCursorVisible(), true);
QCOMPARE(spy.count(), 7);
@@ -3335,7 +3335,7 @@ void tst_qquicktextinput::echoMode()
QQuickView window(testFileUrl("echoMode.qml"));
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(window.rootObject() != 0);
@@ -3411,7 +3411,7 @@ void tst_qquicktextinput::passwordEchoDelay()
QQuickView window(testFileUrl("echoMode.qml"));
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(window.rootObject() != 0);
@@ -3517,7 +3517,7 @@ void tst_qquicktextinput::focusOnPress()
textInputObject->setParentItem(window.contentItem());
window.showNormal();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QCOMPARE(textInputObject->hasFocus(), false);
QCOMPARE(textInputObject->hasActiveFocus(), false);
@@ -3575,7 +3575,7 @@ void tst_qquicktextinput::focusOnPressOnlyOneItem()
QQuickView window(testFileUrl("focusOnlyOneOnPress.qml"));
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QQuickTextInput *first = window.rootObject()->findChild<QQuickTextInput*>("first");
QQuickTextInput *second = window.rootObject()->findChild<QQuickTextInput*>("second");
@@ -3619,7 +3619,7 @@ void tst_qquicktextinput::openInputPanel()
QQuickView view(testFileUrl("openInputPanel.qml"));
view.showNormal();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QQuickTextInput *input = qobject_cast<QQuickTextInput *>(view.rootObject());
QVERIFY(input);
@@ -3708,7 +3708,7 @@ void tst_qquicktextinput::setHAlignClearCache()
input.setParentItem(view.contentItem());
view.show();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QTRY_COMPARE(input.nbPaint, 1);
input.setHAlign(QQuickTextInput::AlignRight);
//Changing the alignment should trigger a repaint
@@ -3728,7 +3728,7 @@ void tst_qquicktextinput::focusOutClearSelection()
input2.componentComplete();
view.show();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QVERIFY(input.hasActiveFocus());
input.select(2,5);
//The selection should work
@@ -3749,7 +3749,7 @@ void tst_qquicktextinput::focusOutNotClearSelection()
input.componentComplete();
view.show();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QVERIFY(input.hasActiveFocus());
input.select(2,5);
@@ -3842,7 +3842,7 @@ void tst_qquicktextinput::preeditAutoScroll()
QQuickView view(testFileUrl("preeditAutoScroll.qml"));
view.show();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QQuickTextInput *input = qobject_cast<QQuickTextInput *>(view.rootObject());
QVERIFY(input);
QVERIFY(input->hasActiveFocus());
@@ -3928,7 +3928,7 @@ void tst_qquicktextinput::preeditCursorRectangle()
QQuickView view(testFileUrl("inputMethodEvent.qml"));
view.show();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QQuickTextInput *input = qobject_cast<QQuickTextInput *>(view.rootObject());
QVERIFY(input);
QVERIFY(input->hasActiveFocus());
@@ -4011,7 +4011,7 @@ void tst_qquicktextinput::inputContextMouseHandler()
view.showNormal();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QTextLayout layout(text);
layout.setFont(input->font());
@@ -4047,7 +4047,7 @@ void tst_qquicktextinput::inputMethodComposing()
QQuickView view(testFileUrl("inputContext.qml"));
view.show();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QQuickTextInput *input = qobject_cast<QQuickTextInput *>(view.rootObject());
QVERIFY(input);
QVERIFY(input->hasActiveFocus());
@@ -4153,7 +4153,7 @@ void tst_qquicktextinput::inputMethodUpdate()
QQuickView view(testFileUrl("inputContext.qml"));
view.show();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QQuickTextInput *input = qobject_cast<QQuickTextInput *>(view.rootObject());
QVERIFY(input);
QVERIFY(input->hasActiveFocus());
@@ -4243,7 +4243,7 @@ void tst_qquicktextinput::cursorRectangleSize()
textInput->setFocus(true);
window->show();
window->requestActivate();
- QTest::qWaitForWindowActive(window);
+ QVERIFY(QTest::qWaitForWindowActive(window));
QVERIFY(textInput->hasActiveFocus());
QInputMethodQueryEvent event(Qt::ImCursorRectangle);
@@ -4275,7 +4275,7 @@ void tst_qquicktextinput::tripleClickSelectsAll()
QQuickView view(QUrl::fromLocalFile(qmlfile));
view.show();
view.requestActivate();
- QTest::qWaitForWindowActive(&view);
+ QVERIFY(QTest::qWaitForWindowActive(&view));
QQuickTextInput* input = qobject_cast<QQuickTextInput*>(view.rootObject());
QVERIFY(input);
@@ -5271,7 +5271,7 @@ void tst_qquicktextinput::keySequence()
textInput->setParentItem(window.contentItem());
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(textInput->hasActiveFocus());
simulateKey(&window, layoutDirection);
@@ -5432,7 +5432,7 @@ void tst_qquicktextinput::undo()
textInput->setParentItem(window.contentItem());
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(textInput->hasActiveFocus());
QVERIFY(!textInput->canUndo());
@@ -5518,7 +5518,7 @@ void tst_qquicktextinput::redo()
textInput->setParentItem(window.contentItem());
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(textInput->hasActiveFocus());
QVERIFY(!textInput->canUndo());
@@ -5850,7 +5850,7 @@ void tst_qquicktextinput::undo_keypressevents()
textInput->setParentItem(window.contentItem());
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(textInput->hasActiveFocus());
simulateKeys(&window, keys);
@@ -5874,7 +5874,7 @@ void tst_qquicktextinput::clear()
textInput->setParentItem(window.contentItem());
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(textInput->hasActiveFocus());
QVERIFY(!textInput->canUndo());
@@ -5956,7 +5956,7 @@ void tst_qquicktextinput::QTBUG_19956()
QQuickView window(testFileUrl(url));
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(window.rootObject() != 0);
QQuickTextInput *input = qobject_cast<QQuickTextInput*>(window.rootObject());
QVERIFY(input);
@@ -5995,7 +5995,7 @@ void tst_qquicktextinput::QTBUG_19956_regexp()
QQuickView window(url);
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(window.rootObject() != 0);
QQuickTextInput *input = qobject_cast<QQuickTextInput*>(window.rootObject());
QVERIFY(input);
@@ -6187,7 +6187,7 @@ void tst_qquicktextinput::keypress_inputMask_withValidator()
textInput->setParentItem(window.contentItem());
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(textInput->hasActiveFocus());
simulateKeys(&window, keys);
@@ -6421,7 +6421,7 @@ void tst_qquicktextinput::setInputMask()
textInput->setParentItem(window.contentItem());
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(textInput->hasActiveFocus());
simulateKey(&window, Qt::Key_Home);
@@ -6557,7 +6557,7 @@ void tst_qquicktextinput::keypress_inputMask()
textInput->setParentItem(window.contentItem());
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(textInput->hasActiveFocus());
simulateKeys(&window, keys);
@@ -6580,7 +6580,7 @@ void tst_qquicktextinput::keypress_inputMethod_inputMask()
textInput->setParentItem(window.contentItem());
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(textInput->hasActiveFocus());
{
@@ -6717,7 +6717,7 @@ void tst_qquicktextinput::fixup()
QQuickWindow window;
window.show();
window.requestActivate();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QQuickTextInput *input = new QQuickTextInput(window.contentItem());
input->setValidator(new TestValidator(input));
diff --git a/tests/auto/quick/qquickwindow/tst_qquickwindow.cpp b/tests/auto/quick/qquickwindow/tst_qquickwindow.cpp
index fe9e8bb1fa..d11f6e8e05 100644
--- a/tests/auto/quick/qquickwindow/tst_qquickwindow.cpp
+++ b/tests/auto/quick/qquickwindow/tst_qquickwindow.cpp
@@ -490,7 +490,7 @@ void tst_qquickwindow::openglContextCreatedSignal()
window.setTitle(QTest::currentTestFunction());
window.show();
- QTest::qWaitForWindowExposed(&window);
+ QVERIFY(QTest::qWaitForWindowExposed(&window));
if (window.rendererInterface()->graphicsApi() != QSGRendererInterface::OpenGL)
QSKIP("Skipping OpenGL context test due to not running with OpenGL");
@@ -506,7 +506,7 @@ void tst_qquickwindow::aboutToStopSignal()
QQuickWindow window;
window.setTitle(QTest::currentTestFunction());
window.show();
- QTest::qWaitForWindowExposed(&window);
+ QVERIFY(QTest::qWaitForWindowExposed(&window));
QSignalSpy spy(&window, SIGNAL(sceneGraphAboutToStop()));
@@ -578,7 +578,7 @@ void tst_qquickwindow::constantUpdatesOnWindow()
bool ok = connect(&window, signal.constData(), &window, SLOT(update()), Qt::DirectConnection);
Q_ASSERT(ok);
window.show();
- QTest::qWaitForWindowExposed(&window);
+ QVERIFY(QTest::qWaitForWindowExposed(&window));
FrameCounter counter;
connect(&window, SIGNAL(frameSwapped()), &counter, SLOT(incr()), Qt::DirectConnection);
@@ -1395,7 +1395,7 @@ void tst_qquickwindow::defaultState()
QQuickWindow cppWindow;
cppWindow.show();
- QTest::qWaitForWindowExposed(&cppWindow);
+ QVERIFY(QTest::qWaitForWindowExposed(&cppWindow));
QCOMPARE(qmlWindow->windowState(), cppWindow.windowState());
}
@@ -1602,7 +1602,7 @@ void tst_qquickwindow::noUpdateWhenNothingChanges()
QQuickRectangle rect(window.contentItem());
window.showNormal();
- QTest::qWaitForWindowExposed(&window);
+ QVERIFY(QTest::qWaitForWindowExposed(&window));
// Many platforms are broken in the sense that that they follow up
// the initial expose with a second expose or more. Let these go
// through before we let the test continue.
@@ -1927,7 +1927,7 @@ void tst_qquickwindow::hideThenDelete()
window.resize(400, 300);
window.show();
- QTest::qWaitForWindowExposed(&window);
+ QVERIFY(QTest::qWaitForWindowExposed(&window));
const bool threaded = QQuickWindowPrivate::get(&window)->context->thread() != QGuiApplication::instance()->thread();
const bool isGL = window.rendererInterface()->graphicsApi() == QSGRendererInterface::OpenGL;
#if QT_CONFIG(opengl)
@@ -2077,7 +2077,7 @@ void tst_qquickwindow::testWindowVisibilityOrder()
QVERIFY(window2);
QVERIFY(window3);
- QTest::qWaitForWindowExposed(window3);
+ QVERIFY(QTest::qWaitForWindowExposed(window3));
QWindowList windows = QGuiApplication::topLevelWindows();
QTRY_COMPARE(windows.size(), 5);
@@ -2099,7 +2099,7 @@ void tst_qquickwindow::testWindowVisibilityOrder()
window4->setVisible(true);
- QTest::qWaitForWindowExposed(window5);
+ QVERIFY(QTest::qWaitForWindowExposed(window5));
QVERIFY(window4->isVisible());
QVERIFY(window5->isVisible());
}
@@ -2113,7 +2113,7 @@ void tst_qquickwindow::blockClosing()
QVERIFY(!window.isNull());
window->setTitle(QTest::currentTestFunction());
window->show();
- QTest::qWaitForWindowExposed(window.data());
+ QVERIFY(QTest::qWaitForWindowExposed(window.data()));
QVERIFY(window->isVisible());
QWindowSystemInterface::handleCloseEvent(window.data());
QVERIFY(window->isVisible());
@@ -2133,7 +2133,7 @@ void tst_qquickwindow::blockCloseMethod()
QVERIFY(!window.isNull());
window->setTitle(QTest::currentTestFunction());
window->show();
- QTest::qWaitForWindowExposed(window.data());
+ QVERIFY(QTest::qWaitForWindowExposed(window.data()));
QVERIFY(window->isVisible());
QVERIFY(QMetaObject::invokeMethod(window.data(), "close", Qt::DirectConnection));
QVERIFY(window->isVisible());
@@ -2154,7 +2154,7 @@ void tst_qquickwindow::crashWhenHoverItemDeleted()
QVERIFY(!window.isNull());
window->setTitle(QTest::currentTestFunction());
window->show();
- QTest::qWaitForWindowActive(window.data());
+ QVERIFY(QTest::qWaitForWindowActive(window.data()));
// Simulate a move from the first rectangle to the second. Crash will happen in here
// Moving instantaneously from (0, 99) to (0, 102) does not cause the crash
@@ -2173,10 +2173,10 @@ void tst_qquickwindow::unloadSubWindow()
QVERIFY(!window.isNull());
window->setTitle(QTest::currentTestFunction());
window->show();
- QTest::qWaitForWindowExposed(window.data());
+ QVERIFY(QTest::qWaitForWindowExposed(window.data()));
QPointer<QQuickWindow> transient;
QTRY_VERIFY(transient = window->property("transientWindow").value<QQuickWindow*>());
- QTest::qWaitForWindowExposed(transient);
+ QVERIFY(QTest::qWaitForWindowExposed(transient));
// Unload the inner window (in nested Loaders) and make sure it doesn't crash
QQuickLoader *loader = window->property("loader1").value<QQuickLoader*>();
@@ -2194,13 +2194,13 @@ void tst_qquickwindow::changeVisibilityInCompleted()
QVERIFY(!window.isNull());
window->setTitle(QTest::currentTestFunction());
window->show();
- QTest::qWaitForWindowExposed(window.data());
+ QVERIFY(QTest::qWaitForWindowExposed(window.data()));
QPointer<QQuickWindow> winVisible;
QTRY_VERIFY(winVisible = window->property("winVisible").value<QQuickWindow*>());
QPointer<QQuickWindow> winVisibility;
QTRY_VERIFY(winVisibility = window->property("winVisibility").value<QQuickWindow*>());
- QTest::qWaitForWindowExposed(winVisible);
- QTest::qWaitForWindowExposed(winVisibility);
+ QVERIFY(QTest::qWaitForWindowExposed(winVisible));
+ QVERIFY(QTest::qWaitForWindowExposed(winVisibility));
QVERIFY(winVisible->isVisible());
QCOMPARE(winVisibility->visibility(), QWindow::Windowed);
@@ -2795,7 +2795,7 @@ void tst_qquickwindow::test_circleMapItem()
QSignalSpy topSpy(mat, SIGNAL(clicked(QQuickMouseEvent *)));
window.show();
- QTest::qWaitForWindowExposed(&window);
+ QVERIFY(QTest::qWaitForWindowExposed(&window));
QTest::qWait(1000);
QPoint pos(50, 50);
diff --git a/tests/auto/quick/scenegraph/tst_scenegraph.cpp b/tests/auto/quick/scenegraph/tst_scenegraph.cpp
index d8d9cd26e0..f62fdd09a2 100644
--- a/tests/auto/quick/scenegraph/tst_scenegraph.cpp
+++ b/tests/auto/quick/scenegraph/tst_scenegraph.cpp
@@ -269,7 +269,7 @@ void tst_SceneGraph::manyWindows()
}
for (int i=0; i<COUNT; ++i) {
QQuickView *view = views.at(i);
- QTest::qWaitForWindowExposed(view);
+ QVERIFY(QTest::qWaitForWindowExposed(view));
QImage content = view->grabWindow();
if (i == 0) {
baseLine = content;
@@ -282,7 +282,7 @@ void tst_SceneGraph::manyWindows()
// Wipe and recreate one (scope pointer delets it...)
delete views.takeLast();
QQuickView *last = createView(file, parent.data(), 100, 100, 100, 100);
- QTest::qWaitForWindowExposed(last);
+ QVERIFY(QTest::qWaitForWindowExposed(last));
views << last;
QVERIFY(compareImages(baseLine, last->grabWindow()));
@@ -295,7 +295,7 @@ void tst_SceneGraph::manyWindows()
}
for (int i=0; i<COUNT; ++i) {
QQuickView *view = views.at(i);
- QTest::qWaitForWindowExposed(view);
+ QVERIFY(QTest::qWaitForWindowExposed(view));
QImage content = view->grabWindow();
QVERIFY(compareImages(content, baseLine));
}
@@ -548,7 +548,7 @@ void tst_SceneGraph::createTextureFromImage()
QQuickView view;
view.show();
- QTest::qWaitForWindowExposed(&view);
+ QVERIFY(QTest::qWaitForWindowExposed(&view));
QTRY_VERIFY(view.isSceneGraphInitialized());
QScopedPointer<QSGTexture> texture(view.createTextureFromImage(image, (QQuickWindow::CreateTextureOptions) flags));
diff --git a/tests/auto/quicktest/signalspy/tst_signalspy.cpp b/tests/auto/quicktest/signalspy/tst_signalspy.cpp
index f54da7819c..c062edd977 100644
--- a/tests/auto/quicktest/signalspy/tst_signalspy.cpp
+++ b/tests/auto/quicktest/signalspy/tst_signalspy.cpp
@@ -73,7 +73,7 @@ void tst_SignalSpy::testCount()
window.resize(200, 200);
window.setSource(testFileUrl("signalspy.qml"));
window.show();
- QTest::qWaitForWindowActive(&window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QVERIFY(window.rootObject() != 0);
QObject *mouseSpy = window.rootObject()->findChild<QObject*>("mouseSpy");