From bdd2b68696738c773224ce2936a161da9d3ad3bc Mon Sep 17 00:00:00 2001 From: Liang Qi Date: Wed, 12 Oct 2022 12:46:51 +0200 Subject: tests: skip tst_selftests on Wayland and XWayland QWindow::requestActivate() is not supported. We have one tst_selftests binary, and will test it with both xcb and wayland qpa plugin. A runtime check and skip will have different restult files, which is not implemented in testlib yet. Task-number: QTBUG-107578 Pick-to: 6.4 6.2 Change-Id: Idc8cb24c6f42a9f0f4dc9493e3fd1a5803ba7ce0 Reviewed-by: Liang Qi --- tests/auto/testlib/selftests/tst_selftests.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'tests/auto/testlib') diff --git a/tests/auto/testlib/selftests/tst_selftests.cpp b/tests/auto/testlib/selftests/tst_selftests.cpp index b70aec2c85..13670257dd 100644 --- a/tests/auto/testlib/selftests/tst_selftests.cpp +++ b/tests/auto/testlib/selftests/tst_selftests.cpp @@ -636,6 +636,11 @@ bool TestLogger::shouldIgnoreTest(const QString &test) const return true; #endif + if (!qEnvironmentVariableIsEmpty("WAYLAND_DISPLAY")) { + qDebug() << "TestLogger::shouldIgnoreTest() ignore" << test << "on wayland/xwayland!"; + return true; + } + // These tests are affected by timing and whether the CPU tick counter // is monotonically increasing. They won't work on some machines so // leave them off by default. Feel free to enable them for your own -- cgit v1.2.3