From bcbf146f0786035b0228eb4bcd13eb2bc6ca5f9b Mon Sep 17 00:00:00 2001 From: Aina Niemetz Date: Mon, 8 Mar 2021 11:10:14 -0800 Subject: [PATCH] Build api tests in build/bin/test/api. (#6076) Previously, api tests where built in build/test/api instead of in the bin directory for the tests. --- test/api/CMakeLists.txt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/test/api/CMakeLists.txt b/test/api/CMakeLists.txt index 33d5f9c37..cc968422f 100644 --- a/test/api/CMakeLists.txt +++ b/test/api/CMakeLists.txt @@ -28,10 +28,13 @@ set(CVC4_API_TEST_FLAGS -D__BUILDING_CVC4_API_TEST -D__STDC_LIMIT_MACROS -D__STDC_FORMAT_MACROS) macro(cvc4_add_api_test name) + set(test_bin_dir ${CMAKE_BINARY_DIR}/bin/test/api/) add_executable(${name} ${name}.cpp) target_link_libraries(${name} main-test) target_compile_definitions(${name} PRIVATE ${CVC4_API_TEST_FLAGS}) - add_test(api/${name} ${CMAKE_CURRENT_BINARY_DIR}/${name}) + set_target_properties(${name} + PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${test_bin_dir}) + add_test(api/${name} ${test_bin_dir}/${name}) set_tests_properties(api/${name} PROPERTIES LABELS "api") add_dependencies(build-apitests ${name}) endmacro() -- 2.30.2