From 08e083e682d92290e36e4fb09abaf0318575dd41 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tor=20Arne=20Vestb=C3=B8?= Date: Fri, 8 Sep 2017 18:42:25 +0200 Subject: Ensure result of all QTest::qWaitFor are verified The qWaitFor functions themselves can not trigger a test failure, as that will not result in the test function exiting early, so every single call to qWaitFor needs to be wrapped in a QVERIFY. Change-Id: Id15a1549f31d06cdbf788e1d84ea431c28636ec8 Reviewed-by: Thiago Macieira --- tests/auto/gui/qopengl/tst_qopengl.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'tests/auto/gui/qopengl') diff --git a/tests/auto/gui/qopengl/tst_qopengl.cpp b/tests/auto/gui/qopengl/tst_qopengl.cpp index 6d9456fa69..82b3657b56 100644 --- a/tests/auto/gui/qopengl/tst_qopengl.cpp +++ b/tests/auto/gui/qopengl/tst_qopengl.cpp @@ -1413,7 +1413,7 @@ void tst_QOpenGL::glxContextWrap() window->setSurfaceType(QWindow::OpenGLSurface); window->setGeometry(0, 0, 10, 10); window->show(); - QTest::qWaitForWindowExposed(window); + QVERIFY(QTest::qWaitForWindowExposed(window)); QPlatformNativeInterface *nativeIf = QGuiApplicationPrivate::instance()->platformIntegration()->nativeInterface(); QVERIFY(nativeIf); @@ -1457,7 +1457,7 @@ void tst_QOpenGL::wglContextWrap() window->setSurfaceType(QWindow::OpenGLSurface); window->setGeometry(0, 0, 256, 256); window->show(); - QTest::qWaitForWindowExposed(window.data()); + QVERIFY(QTest::qWaitForWindowExposed(window.data())); QVariant v = ctx->nativeHandle(); QVERIFY(!v.isNull()); -- cgit v1.2.3