Skip to content

Draft: Help:CTest: multiple ways to set default test timeout

scivision requested to merge scivision/cmake:ctest-timeout into master

Note: this documents existing behavior. The design discussion in #24513 may result in a simple upgrade to CMake code to make one consistent timeout/variable.


For big test suites with each test taking over 30 minutes, I ran into the quirk of multiple distinct defaults CMake/CTest uses for default test timeout. I attempt to highlight this upfront as it took a while to figure out this behavior.

Obviously one can use ctest --timeout or test preset, but for my projects I don't want the default surprising behavior for users to be that long-running tests timeout by default.

The idea is to document for those with plain CMakeLists.txt to have a "safe" default timeout for projects with tests that each take more than 30 minutes when users aren't using presets or --timeout.

Edited by scivision

Merge request reports

Loading