set_tests_properties.rst 1.1 KB

123456789101112131415161718192021222324252627282930313233
  1. set_tests_properties
  2. --------------------
  3. Set a property of the tests.
  4. .. code-block:: cmake
  5. set_tests_properties(test1 [test2...] PROPERTIES prop1 value1 prop2 value2)
  6. Sets a property for the tests. If the test is not found, CMake
  7. will report an error.
  8. Test property values may be specified using
  9. :manual:`generator expressions <cmake-generator-expressions(7)>`
  10. for tests created by the :command:`add_test(NAME)` signature.
  11. .. versionadded:: 3.28
  12. Visibility can be set in other directory scopes using the following option:
  13. ``DIRECTORY <dir>``
  14. The test properties will be set in the ``<dir>`` directory's scope.
  15. CMake must already know about this directory, either by having added it
  16. through a call to :command:`add_subdirectory` or it being the top level
  17. source directory. Relative paths are treated as relative to the current
  18. source directory. ``<dir>`` may reference a binary directory.
  19. See Also
  20. ^^^^^^^^
  21. * :command:`add_test`
  22. * :command:`define_property`
  23. * the more general :command:`set_property` command
  24. * :ref:`Test Properties` for the list of properties known to CMake