summaryrefslogtreecommitdiffstats
path: root/cmake/QtBuild.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'cmake/QtBuild.cmake')
-rw-r--r--cmake/QtBuild.cmake8
1 files changed, 8 insertions, 0 deletions
diff --git a/cmake/QtBuild.cmake b/cmake/QtBuild.cmake
index 8081c7140f..a89ef60994 100644
--- a/cmake/QtBuild.cmake
+++ b/cmake/QtBuild.cmake
@@ -3692,6 +3692,14 @@ function(qt_add_test name)
set_tests_properties(${name} PROPERTIES TIMEOUT ${arg_TIMEOUT})
endif()
+ # Add a ${target}/check makefile target, to more easily test one test.
+ add_custom_target("${name}_check"
+ VERBATIM
+ COMMENT "Running ${CMAKE_CTEST_COMMAND} -V -R \"^${name}$\""
+ COMMAND "${CMAKE_CTEST_COMMAND}" -V -R "^${name}$"
+ )
+ add_dependencies("${name}_check" "${name}")
+
# Get path to <qt_relocatable_install_prefix>/bin, as well as CMAKE_INSTALL_PREFIX/bin, then
# prepend them to the PATH environment variable.
# It's needed on Windows to find the shared libraries and plugins.