Update gtest_helper.cmake
This updates the add_icon_c_test macro in cmake/gtest_helper.cmake:
- The macro is turned into a function to avoid namespace pollution.
- The function is renamed to
fs_add_c_test. - The function now accepts named options
SOURCES(followed by a list of source files of the test) andARGS(followed by a list of command-line arguments for the test). - The old signature of the macro is still supported, i.e. it is possible to call something like
add_c_test(UtilHashTest ctest_util_hash.cpp), but it made sense to me to switch to the new one. - The
UtilFileTesttest is now provided with an extra command-line argument and it runs on${CMAKE_CURRENT_BINARY_DIR}instead of.as it was before !28 (merged).
Edited by Yen-Chen Chen