Don't set graphics system at start of test.
authorJason McDonald <jason.mcdonald@nokia.com>
Mon, 5 Dec 2011 04:10:01 +0000 (14:10 +1000)
committerQt by Nokia <qt-info@nokia.com>
Mon, 5 Dec 2011 06:28:47 +0000 (07:28 +0100)
QApplication::setGraphicsSystem() is a no-op, and even if it wasn't it
would be unwise to force a graphics system that isn't guaranteed to be
included in the Qt build, without including any logic to skip the test
if setting the graphics system failed.

Change-Id: Id9a0a87586872088625de7840b5032d0c3cc48a1
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
tests/auto/gui/image/qvolatileimage/tst_qvolatileimage.cpp

index 87389ff..053160f 100644 (file)
@@ -202,12 +202,5 @@ void tst_QVolatileImage::copy()
     QVERIFY(fuzzyCompareImages(imgA, imgB, 0));
 }
 
-int main(int argc, char *argv[])
-{
-    QApplication::setGraphicsSystem("openvg");
-    QApplication app(argc, argv);
-    tst_QVolatileImage tc;
-    return QTest::qExec(&tc, argc, argv);
-}
-
+QTEST_MAIN(tst_QVolatileImage)
 #include "tst_qvolatileimage.moc"