From ce7fb157f0b8f74025e6927e7b61b1d79de0581c Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Thu, 16 Jul 2015 16:40:42 +0200 Subject: Tests: Do not rely on qCompare(bool, int,...). The overload was added for NokiaX86 and RVCT and is bound for removal. Task-number: QTBUG-47260 Change-Id: Ic67cee8769847956e16cd0470ebcd663a9e98a40 Reviewed-by: Thiago Macieira --- tests/auto/opengl/qgl/tst_qgl.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'tests/auto/opengl/qgl') diff --git a/tests/auto/opengl/qgl/tst_qgl.cpp b/tests/auto/opengl/qgl/tst_qgl.cpp index 9bd82559b7..5a65719380 100644 --- a/tests/auto/opengl/qgl/tst_qgl.cpp +++ b/tests/auto/opengl/qgl/tst_qgl.cpp @@ -2115,25 +2115,25 @@ void tst_QGL::qglContextDefaultBindTexture() QOpenGLFunctions *funcs = QOpenGLContext::currentContext()->functions(); // Make sure the texture IDs returned are valid: - QCOMPARE((bool)funcs->glIsTexture(boundImageTextureId), GL_TRUE); - QCOMPARE((bool)funcs->glIsTexture(boundPixmapTextureId), GL_TRUE); + QCOMPARE(funcs->glIsTexture(boundImageTextureId), GLboolean(GL_TRUE)); + QCOMPARE(funcs->glIsTexture(boundPixmapTextureId), GLboolean(GL_TRUE)); // Make sure the textures are still valid after we delete the image/pixmap: // Also check that although the textures are left intact, the cache entries are removed: delete boundImage; boundImage = 0; - QCOMPARE((bool)funcs->glIsTexture(boundImageTextureId), GL_TRUE); + QCOMPARE(funcs->glIsTexture(boundImageTextureId), GLboolean(GL_TRUE)); QCOMPARE(QGLTextureCache::instance()->size(), startCacheItemCount+1); delete boundPixmap; boundPixmap = 0; - QCOMPARE((bool)funcs->glIsTexture(boundPixmapTextureId), GL_TRUE); + QCOMPARE(funcs->glIsTexture(boundPixmapTextureId), GLboolean(GL_TRUE)); QCOMPARE(QGLTextureCache::instance()->size(), startCacheItemCount); // Finally, make sure QGLContext::deleteTexture deletes the texture IDs: ctx->deleteTexture(boundImageTextureId); ctx->deleteTexture(boundPixmapTextureId); - QCOMPARE((bool)funcs->glIsTexture(boundImageTextureId), GL_FALSE); - QCOMPARE((bool)funcs->glIsTexture(boundPixmapTextureId), GL_FALSE); + QCOMPARE(funcs->glIsTexture(boundImageTextureId), GLboolean(GL_FALSE)); + QCOMPARE(funcs->glIsTexture(boundPixmapTextureId), GLboolean(GL_FALSE)); } #endif -- cgit v1.2.3