CMake/Tests
Brad King 5c6c766da1 Merge topic 'timestamp-percent'
6c54f7b3 string: Teach TIMESTAMP to treat %% as %
2017-01-30 08:43:21 -05:00
..
AliasTarget
Architecture
ArgumentExpansion
Assembler
BuildDepends
BundleGeneratorTest
BundleTest
BundleUtilities
CFBundleTest
CheckCompilerRelatedVariables
CMakeCommands Tests: use cxx_auto_type only if actually available 2017-01-25 21:00:30 +01:00
CMakeLib execute_process: Add ENCODING option for Windows child process output 2016-11-30 09:06:51 -05:00
CMakeOnly C# support: add compiler detection for MSVC 2016-12-15 09:16:30 -05:00
CMakeTestAllGenerators
CMakeTestMultipleConfigures
CMakeTests CMakeParseImplicitLinkInfo: Add support for MSVC invoked by CUDA nvcc 2017-01-12 10:39:01 -05:00
CoberturaCoverage
CommandLineTest
CompatibleInterface
CompileCommandOutput
CompileDefinitions
CompileFeatures Tests: use cxx_auto_type only if actually available 2017-01-25 21:00:30 +01:00
CompileOptions
Complex
ComplexOneConfig
ConfigSources
COnly
Contracts
CPackComponents
CPackComponentsDEB Revert "CPack/DEB: Make package description variable precedence match RPM" 2016-09-24 12:05:06 +02:00
CPackComponentsForAll
CPackComponentsPrefix
CPackTestAllGenerators
CPackWiXGenerator
CrossCompile
CSharpOnly VS: added support for C# (for Visual Studio 2010, 2012, 2013, 2015) 2017-01-13 09:28:13 +01:00
CTestBuildCommandProjectInSubdir
CTestConfig
CTestCoverageCollectGCOV
CTestLimitDashJ
CTestScriptMode
CTestTest
CTestTest2
CTestTestBadExe
CTestTestBadGenerator
CTestTestChecksum
CTestTestCostSerial
CTestTestCrash
CTestTestCycle
CTestTestDepends
CTestTestEmptyBinaryDirectory
CTestTestFailure
CTestTestFdSetSize
CTestTestLabelRegExp
CTestTestLaunchers Tests: Add additional launcher tests 2017-01-10 13:48:59 -05:00
CTestTestMissingDependsExe
CTestTestParallel
CTestTestResourceLock
CTestTestRunScript
CTestTestScheduler
CTestTestSerialInDepends
CTestTestSerialOrder
CTestTestSkipReturnCode
CTestTestStopTime
CTestTestSubdir
CTestTestTimeout
CTestTestUpload
CTestTestVerboseOutput
CTestTestZeroTimeout
Cuda CUDA: Test that CUDA flags are used when device linking executables. 2017-01-12 15:13:31 -05:00
CudaOnly CUDA: Enable CudaOnly.SeparateCompilation test runtime calls 2017-01-12 10:39:04 -05:00
CustComDepend
CustomCommand add_custom_{command,target}: Add COMMAND_EXPAND_LISTS option 2017-01-13 20:02:16 -06:00
CustomCommandByproducts
CustomCommandWorkingDirectory
CxxDialect
CxxOnly
CxxSubdirC
DelphiCoverage
Dependency
DoubleProject
EmptyDepends
EmptyLibrary
EmptyProperty
Environment
ExportImport
ExternalOBJ
ExternalProject ExternalProject: Allow passing config flags to git clone 2016-11-09 15:54:13 -05:00
ExternalProjectLocal ExternalProject: Fix UPDATE_DISCONNECTED with empty update steps 2016-11-15 08:45:04 -05:00
ExternalProjectSourceSubdir ExternalProject: Add SOURCE_SUBDIR option 2016-08-16 13:18:18 -04:00
ExternalProjectSubdir
ExternalProjectUpdate
FindBoost
FindBZip2 Tests: Add FindBZip2 unit tests 2016-09-09 11:42:35 -04:00
FindGSL
FindGTest
FindGTK2
FindICU
FindJsonCpp
FindLibRHash FindLibRHash: Add module to find the librhash package 2016-11-10 08:29:38 -05:00
FindLibUV FindLibUV: Add module to find libuv package 2016-08-31 09:05:14 -04:00
FindLTTngUST
FindMatlab FindMatlab: adding handling of component "MAT" 2016-08-30 14:50:20 +02:00
FindModulesExecuteAll
FindOpenCL
FindOpenGL FindOpenGL: Provide imported targets for GL and GLU 2016-12-02 15:11:49 -05:00
FindOpenSSL
FindPackageModeMakefileTest Test: Remove condition for CMake version no longer supported 2016-10-10 10:09:54 -04:00
FindPackageTest find_package: Optionally sort globbed directories in a meaningful order 2016-09-15 13:35:25 -04:00
FindPNG
FindThreads
FindTIFF
FindVulkan
FindXalanC
FindXercesC
ForceInclude
Fortran Tests: Split Fortran module testing into separate FortranModules test 2016-09-22 14:52:01 -04:00
FortranC
FortranModules Ninja: Add source location as include directory for preprocessed files 2016-09-27 08:11:08 -04:00
FortranOnly
Framework Ninja: Fix POST_BUILD commands on macOS Frameworks 2016-10-13 14:04:12 -04:00
FunctionTest
GeneratorExpression Merge topic 'genex-if' 2017-01-27 09:04:58 -05:00
GhsMulti
GhsMultiDuplicateSourceFilenames
IncludeDirectories Xcode: Properly mark SYSTEM includes as such 2016-12-27 22:18:30 +01:00
InterfaceLibrary Allow NO_SYSTEM_FROM_IMPORTED on imported INTERFACE libraries 2016-11-21 11:42:01 -05:00
InterfaceLinkLibraries
iOSNavApp
IPO
JacocoCoverage
Java
JavaExportImport
JavaJavah
JavascriptCoverage
JCTest
Jump
LibName
LinkDirectory
LinkFlags
LinkLanguage
LinkLine
LinkLineOrder
LinkStatic
LoadCommand
LoadCommandOneConfig
MacroTest
MacRuntimePath Add a BUILD_RPATH target property specifying build-tree RPATH entries 2016-10-03 13:42:27 -04:00
MakeClean
MathTest math(EXPR): Add support for unary + and - expressions 2016-10-14 15:35:15 -04:00
MFC
MissingInstall
MissingSourceFile
Module ExternalData: Add support for SHA-3 algorithms 2016-11-11 11:46:00 -05:00
ModuleDefinition
MSManifest
MumpsCoverage
NewlineArgs
ObjC++
ObjectLibrary
OutDir
OutOfBinary
OutOfSource
PDBDirectoryAndName
PerConfig
Plugin
Policy0002
PolicyScope
PositionIndependentTargets
PrecompiledHeader
PreOrder
Preprocess Tests: Make Preprocess test work in RelWithDebInfo and MinSizeRel 2017-01-27 09:09:15 -05:00
Properties
PythonCoverage
Qt4And5Automoc
Qt4Deploy
Qt4Targets
QtAutogen AUTOGEN: Tests: AUTORCC SKIP_AUTORCC and SKIP_AUTOGEN test 2017-01-10 12:49:17 +01:00
QtAutomocNoQt
QtAutoUicInterface QtAutogen: Tests: Don't use std::auto_ptr 2016-12-07 08:24:06 -05:00
ReturnTest
RunCMake string: Teach TIMESTAMP to treat %% as % 2017-01-27 09:25:37 -05:00
RuntimePath
SameName
SBCS
Server cmake-server: Better error reporting during handshake 2016-10-27 14:18:42 -04:00
SetLang
Simple
SimpleCOnly
SimpleExclude
SimpleInstall
SimpleInstallS2
SourceFileProperty
SourceGroups source_group: Add options create groups matching directory tree 2017-01-16 10:52:48 -05:00
SourcesProperty
StagingPrefix
StringFileTest
SubDir
SubDirSpaces
SubProject
SwiftMix
SwiftOnly Xcode: Add option to set Swift language version 2016-09-26 08:46:23 -04:00
SwigTest SwigTest: Update for swig_add_library and add lua example 2016-11-11 08:14:10 +01:00
SystemInformation
TargetName
TestDriver
Testing
TestsWorkingDirectory
TryCompile
Tutorial
Unset
VariableUnusedViaSet
VariableUnusedViaUnset
VariableUsage
Visibility
VSExcludeFromDefaultBuild
VSExternalInclude VS15: Add Visual Studio 15 generator 2016-09-07 15:49:08 -04:00
VSGNUFortran
VSMASM
VSMidl
VSNsightTegra Tests: Fix VSNsightTegra test on Android NDK r12b 2016-10-18 13:32:50 -04:00
VSProjectInSubdir
VSResource
VSResourceNinjaForceRSP
VSWindowsFormsResx
VSWinStorePhone
VSXaml
WarnUnusedCliUnused
Wrapping
X11
XCTest
.NoDartCoverage
bootstrap.bat.in
BootstrapTest.cmake BootstrapTest: Use --parallel=... argument. 2016-10-21 18:22:44 +02:00
CheckFortran.cmake Simplify CMake per-source license notices 2016-09-27 15:14:44 -04:00
CMakeBuildTest.cmake.in
CMakeCopyright.cmake
CMakeInstall.cmake
CMakeLists.txt VS: added support for C# (for Visual Studio 2010, 2012, 2013, 2015) 2017-01-13 09:28:13 +01:00
CTestUpdateBZR.cmake.in
CTestUpdateCommon.cmake
CTestUpdateCVS.cmake.in
CTestUpdateGIT.cmake.in
CTestUpdateGIT.sh.in
CTestUpdateHG.cmake.in
CTestUpdateP4.cmake.in
CTestUpdateSVN.cmake.in
EnforceConfig.cmake.in
README
test_clean.cmake.in

If you think about adding a new testcase then here is a small checklist you
can run through to find a proper place for it. Go through the list from the
beginning and stop once you find something that matches your tests needs,
i.e. if you will test a module and only need the configure mode use the
instructions from section 2, not 3.

1. Your testcase can run in CMake script mode, i.e. "cmake -P something"

Put your test in Tests/CMakeTests/ directory as a .cmake.in file. It will be
put into the test binary directory by configure_file(... @ONLY) and run from
there. Use the AddCMakeTest() macro in Tests/CMakeTests/CMakeLists.txt to add
your test to the test runs.

2. Your test needs CMake to run in configure mode, but will not build anything

This includes tests that will build something using try_compile() and friends,
but nothing that expects add_executable(), add_library(), or add_test() to run.

If the test configures the project only once and it must succeed then put it
into the Tests/CMakeOnly/ directory.  Create a subdirectory named like your
test and write the CMakeLists.txt you need into that subdirectory. Use the
add_CMakeOnly_test() macro from Tests/CMakeOnly/CMakeLists.txt to add your
test to the test runs.

If the test configures the project with multiple variations and verifies
success or failure each time then put it into the Tests/RunCMake/ directory.
Read the instructions in Tests/RunCMake/CMakeLists.txt to add a test.

3. If you are testing something from the Modules directory

Put your test in the Tests/Modules/ directory. Create a subdirectory there
named after your test. Use the ADD_TEST_MACRO macro from Tests/CMakeLists.txt
to add your test to the test run. If you have put your stuff in
Tests/Modules/Foo then you call it using ADD_TEST_MACRO(Module.Foo Foo).

4. You are doing other stuff.

Find a good place ;) In doubt mail to cmake-developers@cmake.org and ask for
advise.