I am currently having trouble changing the directory CTest in when using the RUN_TESTS project generated by CMake. Currently CMAKE_RUNTIME_OUTPUT_DIRECTORY is set to a custom path. As a result when CTest attempts to run, it is doing so from a directory that contains no binaries.
As a temporary workaround I am calling ADD_TEST using ${RUNTIME_OUTPUT_DIRECTORY}\test but I am not sure if this is the correct solution. Is there a way a better way change the default directory used by CTest?
If your ADD_EXECUTABLE target is say
my_exeand your test namemy_test, you should be able to callADD_TESTlike:For further info, run