2013-10-15 19:17:36 +04:00
|
|
|
ctest_test
|
|
|
|
----------
|
|
|
|
|
2015-05-07 23:10:20 +03:00
|
|
|
Perform the :ref:`CTest Test Step` as a :ref:`Dashboard Client`.
|
2013-10-15 19:17:36 +04:00
|
|
|
|
|
|
|
::
|
|
|
|
|
2015-05-07 23:10:20 +03:00
|
|
|
ctest_test([BUILD <build-dir>] [APPEND]
|
|
|
|
[START <start-number>]
|
|
|
|
[END <end-number>]
|
|
|
|
[STRIDE <stride-number>]
|
|
|
|
[EXCLUDE <exclude-regex>]
|
|
|
|
[INCLUDE <include-regex>]
|
|
|
|
[EXCLUDE_LABEL <label-exclude-regex>]
|
|
|
|
[INCLUDE_LABEL <label-include-regex>]
|
|
|
|
[PARALLEL_LEVEL <level>]
|
2015-06-09 15:50:44 +03:00
|
|
|
[TEST_LOAD <threshold>]
|
2015-05-07 23:10:20 +03:00
|
|
|
[SCHEDULE_RANDOM <ON|OFF>]
|
|
|
|
[STOP_TIME <time-of-day>]
|
|
|
|
[RETURN_VALUE <result-var>]
|
2016-07-28 22:12:43 +03:00
|
|
|
[CAPTURE_CMAKE_ERROR <result-var>]
|
2015-05-07 23:10:20 +03:00
|
|
|
[QUIET]
|
|
|
|
)
|
|
|
|
|
|
|
|
Run tests in the project build tree and store results in
|
|
|
|
``Test.xml`` for submission with the :command:`ctest_submit` command.
|
|
|
|
|
|
|
|
The options are:
|
|
|
|
|
|
|
|
``BUILD <build-dir>``
|
|
|
|
Specify the top-level build directory. If not given, the
|
|
|
|
:variable:`CTEST_BINARY_DIRECTORY` variable is used.
|
|
|
|
|
|
|
|
``APPEND``
|
2016-10-14 21:42:48 +03:00
|
|
|
Mark ``Test.xml`` for append to results previously submitted to a
|
2015-05-07 23:10:20 +03:00
|
|
|
dashboard server since the last :command:`ctest_start` call.
|
|
|
|
Append semantics are defined by the dashboard server in use.
|
2016-10-14 21:42:48 +03:00
|
|
|
This does *not* cause results to be appended to a ``.xml`` file
|
|
|
|
produced by a previous call to this command.
|
2015-05-07 23:10:20 +03:00
|
|
|
|
|
|
|
``START <start-number>``
|
|
|
|
Specify the beginning of a range of test numbers.
|
|
|
|
|
|
|
|
``END <end-number>``
|
|
|
|
Specify the end of a range of test numbers.
|
|
|
|
|
|
|
|
``STRIDE <stride-number>``
|
2015-06-08 17:50:25 +03:00
|
|
|
Specify the stride by which to step across a range of test numbers.
|
2015-05-07 23:10:20 +03:00
|
|
|
|
|
|
|
``EXCLUDE <exclude-regex>``
|
|
|
|
Specify a regular expression matching test names to exclude.
|
|
|
|
|
|
|
|
``INCLUDE <include-regex>``
|
|
|
|
Specify a regular expression matching test names to include.
|
|
|
|
Tests not matching this expression are excluded.
|
|
|
|
|
|
|
|
``EXCLUDE_LABEL <label-exclude-regex>``
|
|
|
|
Specify a regular expression matching test labels to exclude.
|
|
|
|
|
|
|
|
``INCLUDE_LABEL <label-include-regex>``
|
|
|
|
Specify a regular expression matching test labels to include.
|
|
|
|
Tests not matching this expression are excluded.
|
|
|
|
|
|
|
|
``PARALLEL_LEVEL <level>``
|
|
|
|
Specify a positive number representing the number of tests to
|
|
|
|
be run in parallel.
|
|
|
|
|
2015-06-09 15:50:44 +03:00
|
|
|
``TEST_LOAD <threshold>``
|
|
|
|
While running tests in parallel, try not to start tests when they
|
|
|
|
may cause the CPU load to pass above a given threshold. If not
|
|
|
|
specified the :variable:`CTEST_TEST_LOAD` variable will be checked,
|
|
|
|
and then the ``--test-load`` command-line argument to :manual:`ctest(1)`.
|
|
|
|
See also the ``TestLoad`` setting in the :ref:`CTest Test Step`.
|
|
|
|
|
2015-05-07 23:10:20 +03:00
|
|
|
``SCHEDULE_RANDOM <ON|OFF>``
|
|
|
|
Launch tests in a random order. This may be useful for detecting
|
|
|
|
implicit test dependencies.
|
|
|
|
|
|
|
|
``STOP_TIME <time-of-day>``
|
|
|
|
Specify a time of day at which the tests should all stop running.
|
|
|
|
|
|
|
|
``RETURN_VALUE <result-var>``
|
|
|
|
Store in the ``<result-var>`` variable ``0`` if all tests passed.
|
|
|
|
Store non-zero if anything went wrong.
|
|
|
|
|
2016-07-28 22:12:43 +03:00
|
|
|
``CAPTURE_CMAKE_ERROR <result-var>``
|
|
|
|
Store in the ``<result-var>`` variable -1 if there are any errors running
|
|
|
|
the command and prevent ctest from returning non-zero if an error occurs.
|
|
|
|
|
2015-05-07 23:10:20 +03:00
|
|
|
``QUIET``
|
|
|
|
Suppress any CTest-specific non-error messages that would have otherwise
|
|
|
|
been printed to the console. Output from the underlying test command is not
|
|
|
|
affected. Summary info detailing the percentage of passing tests is also
|
|
|
|
unaffected by the ``QUIET`` option.
|
2015-09-17 17:55:56 +03:00
|
|
|
|
|
|
|
See also the :variable:`CTEST_CUSTOM_MAXIMUM_PASSED_TEST_OUTPUT_SIZE`
|
|
|
|
and :variable:`CTEST_CUSTOM_MAXIMUM_FAILED_TEST_OUTPUT_SIZE` variables.
|