Run project testing script
-
Download project testing script.
-
Put the project testing script to a dashboard directory (for example,
~/Dashboards/project
orc:/Dashboards/project
). -
Run CTest tool from a command line:
$ ctest -VV -S ~/Dashboards/project/project_test.cmake
-
Add the above command to a scheduler (for example,
cron
) or to a CI system (like buildbot, jenkins, travis).
For CTest tool command line options please refer to CTest Documentation.
Configure the testing script
The CTest Extension module can be configured in three ways:
-
Create parent CMake script, which will define all required variables and then include the project's testing script:
set(CTEST_TARGET_SYSTEM "Linux-Ubuntu-14.04-x64") set(CTEST_MODEL "Performance") include("~/Dashboards/project/project_test.cmake")
-
Pass the options with CTest command line:
$ ctest -VV -S ~/Dashboards/project/project_test.cmake \ -DCTEST_TARGET_SYSTEM="Linux-Ubuntu-14.04-x64" \ -DCTEST_MODEL="Nightly"
-
Set the options as environment variables prior to CTest call:
$ export CTEST_TARGET_SYSTEM="Linux-Ubuntu-14.04-x64" $ export CTEST_MODEL="Nightly" $ ctest -VV -S ~/Dashboards/project/project_test.cmake