summaryrefslogtreecommitdiffstats
path: root/src/testlib/CMakeLists.txt
diff options
context:
space:
mode:
authorAlexandru Croitor <alexandru.croitor@qt.io>2020-07-01 11:00:00 +0200
committerAlexandru Croitor <alexandru.croitor@qt.io>2020-07-01 14:55:26 +0200
commitbb5757f0cd7903c04f5d49fb0bf743b896639956 (patch)
tree7706d08a7f022b98259375d0f494d747fd03352b /src/testlib/CMakeLists.txt
parentab6861b01ff9c14fd1648cb725da17d1ebf3faea (diff)
CMake: Add "cmake" keyword for test blacklisting
Certain tests fail only on CMake configurations. We need the capability to ignore these failures, without removing the qmake-built-Qt coverage for now. The keyword is enabled when Qt is built with CMake. So it doesn't matter if the final test is built with CMake or qmake. Task-number: QTBUG-85364 Change-Id: I157fe3d9254b589ef1e84022c01f4487ff834d27 Reviewed-by: Kai Koehne <kai.koehne@qt.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Diffstat (limited to 'src/testlib/CMakeLists.txt')
-rw-r--r--src/testlib/CMakeLists.txt3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/testlib/CMakeLists.txt b/src/testlib/CMakeLists.txt
index 0dc6f29505..22df4c93b4 100644
--- a/src/testlib/CMakeLists.txt
+++ b/src/testlib/CMakeLists.txt
@@ -133,4 +133,7 @@ qt_add_docs(Test
# special case begin
qt_apply_testlib_coverage_options(Test)
+
+# Allow blacklisting tests depending on whether testlib was built as part of a CMake build.
+target_compile_definitions(Test PRIVATE QT_CMAKE_BUILD)
# special case end