CMakeLists.txt: Add TESTRUNNER_ARGS

Make it easy to disable certain tests if they can't be run.
This commit is contained in:
yangfl 2019-01-06 14:16:53 +08:00
parent a116ed3dbe
commit 754e6befb3

View file

@ -1191,7 +1191,7 @@ if(GTEST_FOUND OR DOWNLOAD_GTEST)
list(APPEND TARGETS_LINK ${TARGET_TESTRUNNER}) list(APPEND TARGETS_LINK ${TARGET_TESTRUNNER})
add_custom_target(run_tests add_custom_target(run_tests
COMMAND $<TARGET_FILE:${TARGET_TESTRUNNER}> COMMAND $<TARGET_FILE:${TARGET_TESTRUNNER}> ${TESTRUNNER_ARGS}
COMMENT Running tests COMMENT Running tests
DEPENDS ${TARGET_TESTRUNNER} DEPENDS ${TARGET_TESTRUNNER}
USES_TERMINAL USES_TERMINAL