summaryrefslogtreecommitdiffstats
path: root/tests/auto/qgl/tst_qgl.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/qgl/tst_qgl.cpp')
-rw-r--r--tests/auto/qgl/tst_qgl.cpp27
1 files changed, 26 insertions, 1 deletions
diff --git a/tests/auto/qgl/tst_qgl.cpp b/tests/auto/qgl/tst_qgl.cpp
index 8ee494f..7fe461c 100644
--- a/tests/auto/qgl/tst_qgl.cpp
+++ b/tests/auto/qgl/tst_qgl.cpp
@@ -2252,5 +2252,30 @@ void tst_QGL::textureCleanup()
#endif
}
-QTEST_MAIN(tst_QGL)
+class tst_QGLDummy : public QObject
+{
+Q_OBJECT
+
+public:
+ tst_QGLDummy() {}
+
+private slots:
+ void qglSkipTests() {
+ QSKIP("QGL not supported on this system.", SkipAll);
+ }
+};
+
+int main(int argc, char **argv)
+{
+ QApplication app(argc, argv);
+ QTEST_DISABLE_KEYPAD_NAVIGATION \
+ QGLWidget glWidget;
+ if (!glWidget.isValid()) {
+ tst_QGLDummy tc;
+ return QTest::qExec(&tc, argc, argv);
+ }
+ tst_QGL tc;
+ return QTest::qExec(&tc, argc, argv);
+}
+
#include "tst_qgl.moc"