summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJüri Valdmann <juri.valdmann@qt.io>2018-10-19 12:39:12 +0200
committerJüri Valdmann <juri.valdmann@qt.io>2018-10-20 20:38:59 +0000
commitcea2b5510c28d1057018007d65589fecee62b0d8 (patch)
treeb6ff82dd7f084e9bcdc06ed3fb4f85f6beddc517
parent10b8ed816d0dff4321d5a8b0723a8090b2058678 (diff)
Fix building tests with -no-gui
Change-Id: I37307080e5adc334fcfcdd2fee650d675228a746 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
-rw-r--r--mkspecs/features/ctest_testcase_common.prf4
-rw-r--r--tests/auto/corelib/itemmodels/itemmodels.pro4
-rw-r--r--tests/auto/other/other.pro4
-rw-r--r--tests/auto/testlib/selftests/selftests.pri6
4 files changed, 10 insertions, 8 deletions
diff --git a/mkspecs/features/ctest_testcase_common.prf b/mkspecs/features/ctest_testcase_common.prf
index 0d5ff5f89c..63e31f5415 100644
--- a/mkspecs/features/ctest_testcase_common.prf
+++ b/mkspecs/features/ctest_testcase_common.prf
@@ -48,8 +48,8 @@ for (dep, dependentmodules): \
dependentmodules = $$join(mod_deps, ";")
QT_FOR_CONFIG += gui-private
-qtConfig(angle): CMAKE_GL_DEFINES = -DQT_WITH_ANGLE=True
-!qtConfig(egl): CMAKE_GL_DEFINES += -DNO_EGL=True
+qtHaveModule(gui):qtConfig(angle): CMAKE_GL_DEFINES = -DQT_WITH_ANGLE=True
+qtHaveModule(gui):!qtConfig(egl): CMAKE_GL_DEFINES += -DNO_EGL=True
CMAKE_MODULE_VERSIONS =
CMAKE_MODULES_UNDER_TEST =
diff --git a/tests/auto/corelib/itemmodels/itemmodels.pro b/tests/auto/corelib/itemmodels/itemmodels.pro
index bcb6e604f8..cca350ad43 100644
--- a/tests/auto/corelib/itemmodels/itemmodels.pro
+++ b/tests/auto/corelib/itemmodels/itemmodels.pro
@@ -1,9 +1,9 @@
TEMPLATE=subdirs
-SUBDIRS = qabstractitemmodel \
- qstringlistmodel \
+SUBDIRS = qstringlistmodel
qtHaveModule(gui): SUBDIRS += \
+ qabstractitemmodel \
qabstractproxymodel \
qidentityproxymodel \
qitemselectionmodel \
diff --git a/tests/auto/other/other.pro b/tests/auto/other/other.pro
index 61a464356c..d70c895dec 100644
--- a/tests/auto/other/other.pro
+++ b/tests/auto/other/other.pro
@@ -48,9 +48,9 @@ cross_compile: SUBDIRS -= \
atwrapper \
compiler
-winrt|!qtConfig(accessibility): SUBDIRS -= qaccessibility
+winrt|!qtHaveModule(gui)|!qtConfig(accessibility): SUBDIRS -= qaccessibility
-!qtConfig(accessibility-atspi-bridge): SUBDIRS -= qaccessibilitylinux
+!qtHaveModule(gui)|!qtConfig(accessibility-atspi-bridge): SUBDIRS -= qaccessibilitylinux
!qtConfig(process): SUBDIRS -= qprocess_and_guieventloop
diff --git a/tests/auto/testlib/selftests/selftests.pri b/tests/auto/testlib/selftests/selftests.pri
index 498d1653c0..05ed6d9905 100644
--- a/tests/auto/testlib/selftests/selftests.pri
+++ b/tests/auto/testlib/selftests/selftests.pri
@@ -27,10 +27,8 @@ SUBPROGRAMS = \
findtestdata \
float \
globaldata \
- keyboard \
longstring \
maxwarnings \
- mouse \
multiexec \
pairdiagnostics \
printdatatags \
@@ -52,5 +50,9 @@ SUBPROGRAMS = \
warnings \
xunit
+qtHaveModule(gui): SUBPROGRAMS += \
+ keyboard \
+ mouse
+
INCLUDEPATH += ../../../../shared/
HEADERS += ../../../../shared/emulationdetector.h