diff options
author | Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> | 2015-07-24 15:32:22 +0200 |
---|---|---|
committer | Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> | 2015-07-27 18:45:21 +0000 |
commit | e6846850a51cbe2a8cc8b9398430d1dd4f6ac7b3 (patch) | |
tree | ee08e04b3f0eca16f7f12f2c2392eee9dbae41d8 /tests/auto/quick/qquickwindow | |
parent | 0959281be22c2d3317f010ac117010fdf990df7a (diff) |
tests/quick: Replace Q[TRY]_VERIFY(a == b) by Q[TRY]_COMPARE(a, b).
- Replace Q[TRY]_VERIFY(pointer == 0) by Q[TRY]_VERIFY(!pointer).
- Replace Q[TRY]_VERIFY(smartPointer == 0) by
Q[TRY]_VERIFY(smartPointer.isNull()).
- Replace Q[TRY]_VERIFY(a == b) by Q[TRY]_COMPARE(a, b) and
add casts where necessary. The values will then be logged
should a test fail.
Change-Id: Ib9f4c2486af23c47990be4b9e004b965de226dcc
Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
Diffstat (limited to 'tests/auto/quick/qquickwindow')
-rw-r--r-- | tests/auto/quick/qquickwindow/tst_qquickwindow.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/auto/quick/qquickwindow/tst_qquickwindow.cpp b/tests/auto/quick/qquickwindow/tst_qquickwindow.cpp index 51a80ea0e9..2c7a3c933b 100644 --- a/tests/auto/quick/qquickwindow/tst_qquickwindow.cpp +++ b/tests/auto/quick/qquickwindow/tst_qquickwindow.cpp @@ -978,7 +978,7 @@ void tst_qquickwindow::clearWindow() delete window; - QVERIFY(item->window() == 0); + QVERIFY(!item->window()); delete item; } @@ -1232,7 +1232,7 @@ void tst_qquickwindow::headless() if (threaded) { QTRY_COMPARE(invalidated.size(), 1); - QVERIFY(window->openglContext() == 0); + QVERIFY(!window->openglContext()); } if (QGuiApplication::platformName() == QLatin1String("windows") @@ -1242,7 +1242,7 @@ void tst_qquickwindow::headless() // Destroy the native windowing system buffers window->destroy(); - QVERIFY(window->handle() == 0); + QVERIFY(!window->handle()); // Show and verify that we are back and running window->show(); @@ -1609,7 +1609,7 @@ void tst_qquickwindow::hideThenDelete() if (!persistentGL) QVERIFY(openglDestroyed->size() > 0); else - QVERIFY(openglDestroyed->size() == 0); + QCOMPARE(openglDestroyed->size(), 0); } else { QCOMPARE(sgInvalidated->size(), 0); QCOMPARE(openglDestroyed->size(), 0); |