[CMake] Skipping Tests if FIXTURES_SETUP is skipped

Jörg Kreuzberger j.kreuzberger at procitec.de
Tue May 8 10:47:03 EDT 2018


Hi!

I'm working with the FIXTURES feature of the ctest's and find it very usefull.

I want to skip certain tests if the setup test is skipped

so i added a tests with SKIP_RETURN_CODE feature and set it as FIXTURES_SETUP "tty" (just calling command tty -s on unix)
my assumption is that now all tests with FIXTURES_REQUIRED "tty" are also skipped.
but it does not seem so. The setup test is skipped, but all tests are executed (and fail)

The documentation only says the if the SETUP tests FAILS, the tests requiring the FIXTURES_SETUP are not executed,
but then the setup test itself goes into FAIL count, i want it to be skipped

It this a bug or are there better solutions than my hack? I now generate files in setup test and add them as REQUIRED_FILES in the dependent tests.


Any help appreciated,
Joerg



More information about the CMake mailing list