set_tests_properties.rst 1.2 KB

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