summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorEskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>2022-06-30 07:01:53 +0200
committerQt Cherry-pick Bot <cherrypick_bot@qt-project.org>2022-07-13 12:35:11 +0000
commit70ec343b9ed40edb1d491446febfa8ffcf2bcffa (patch)
treee050ea1c7d5e5e9ee838863480c0059ca740f28d /tests
parent34751307bf08b37d967c7d290c6c1c2eebfb2eee (diff)
Skip test which depends on window activations on Wayland
Wayland does not support window activation, so rather than skipping tests based on platform name, we can use the platform capability (which will also cover future platforms with the same issue) Task-number: QTBUG-104241 Change-Id: Ibf5f8968f3979b789ef68f92768419bef4500fb3 Reviewed-by: Inho Lee <inho.lee@qt.io> (cherry picked from commit 3fee97c4ab0796fcafcdea692ff7c7e83005a2aa) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/widgets/widgets/qopenglwidget/tst_qopenglwidget.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/auto/widgets/widgets/qopenglwidget/tst_qopenglwidget.cpp b/tests/auto/widgets/widgets/qopenglwidget/tst_qopenglwidget.cpp
index 49718a5e87..f90879ab12 100644
--- a/tests/auto/widgets/widgets/qopenglwidget/tst_qopenglwidget.cpp
+++ b/tests/auto/widgets/widgets/qopenglwidget/tst_qopenglwidget.cpp
@@ -20,6 +20,8 @@
#include <private/qstatictext_p.h>
#include <private/qopengltextureglyphcache_p.h>
#include <qpa/qplatformintegration.h>
+#include <private/qguiapplication_p.h>
+#include <qpa/qplatformintegration.h>
class tst_QOpenGLWidget : public QObject
{
@@ -652,8 +654,8 @@ void tst_QOpenGLWidget::stackWidgetOpaqueChildIsVisible()
#ifdef Q_OS_ANDROID
QSKIP("Crashes on Android, figure out why (QTBUG-102043)");
#endif
- if (QGuiApplication::platformName().startsWith(QLatin1String("wayland"), Qt::CaseInsensitive))
- QSKIP("Wayland: This fails. Figure out why.");
+ if (!QGuiApplicationPrivate::platformIntegration()->hasCapability(QPlatformIntegration::WindowActivation))
+ QSKIP("Platform does not support window activation");
if (QGuiApplication::platformName().startsWith(QLatin1String("offscreen"), Qt::CaseInsensitive))
QSKIP("Offscreen: This fails.");