1
0
mirror of synced 2024-12-22 12:40:00 +01:00

Fix Google Test example

This commit is contained in:
Ruben Anders 2024-03-25 23:02:53 +00:00 committed by Henry Schreiner
parent 562e3ec2c4
commit fd21e242d5

View File

@ -64,8 +64,8 @@ macro(package_add_test TESTNAME)
# see https://cmake.org/cmake/help/v3.10/module/GoogleTest.html for more options to pass to it
gtest_discover_tests(${TESTNAME}
# set a working directory so your project root so that you can find test data via paths relative to the project root
WORKING_DIRECTORY ${PROJECT_DIR}
PROPERTIES VS_DEBUGGER_WORKING_DIRECTORY "${PROJECT_DIR}"
WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
PROPERTIES VS_DEBUGGER_WORKING_DIRECTORY "${PROJECT_SOURCE_DIR}"
)
set_target_properties(${TESTNAME} PROPERTIES FOLDER tests)
endmacro()