Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
cmake-variables.qdoc
Go to the documentation of this file.
1
// Copyright (C) 2024 The Qt Company Ltd.
2
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
3
4
/*!
5
\group cmake-variables-qttest
6
\title CMake Variables in Qt6 Test
7
\brief Lists CMake variables defined in Qt6::Test.
8
9
The following CMake variables are defined when Qt6::Test is loaded, for instance
10
with
11
12
\badcode
13
find_package(Qt6 REQUIRED COMPONENTS Test)
14
\endcode
15
16
\sa{CMake Variable Reference}
17
*/
18
19
/*!
20
\page cmake-variable-qt-skip-default-testcase-dirs.html
21
\ingroup cmake-variables-qttest
22
23
\title QT_SKIP_DEFAULT_TESTCASE_DIRS
24
\target cmake-variable-QT_SKIP_DEFAULT_TESTCASE_DIRS
25
26
\cmakevariablesince 6.9
27
\preliminarycmakevariable
28
29
\summary {Disables the test case directory definitions for the Qt Test targets.}
30
31
Controls the default value of the
32
\l {cmake-target-property-QT_SKIP_DEFAULT_TESTCASE_DIRS}{QT_SKIP_DEFAULT_TESTCASE_DIRS}
33
target property.
34
\note Supported by CMake versions >= 3.23.
35
36
\badcode
37
set(QT_SKIP_DEFAULT_TESTCASE_DIRS TRUE)
38
...
39
qt_add_executable(mytest1 main1.cpp)
40
target_link_libraries(mytest1 PRIVATE Qt6::Test)
41
...
42
qt_add_executable(mytest2 main2.cpp)
43
target_link_libraries(mytest2 PRIVATE Qt6::Test)
44
\endcode
45
46
The \c QT_TESTCASE_SOURCEDIR and \c QT_TESTCASE_BUILDDIR macros will remain
47
undefined when compiling \c mytest1 and \c mytest2.
48
49
\sa QFINDTESTDATA,
50
{cmake-target-property-QT_SKIP_DEFAULT_TESTCASE_DIRS}{QT_SKIP_DEFAULT_TESTCASE_DIRS}
51
*/
qtbase
src
testlib
doc
src
cmake
cmake-variables.qdoc
Generated on
for Qt by
1.14.0