diff options
author | Egor Tensin <Egor.Tensin@gmail.com> | 2021-04-07 00:55:57 +0300 |
---|---|---|
committer | Egor Tensin <Egor.Tensin@gmail.com> | 2021-04-07 00:55:57 +0300 |
commit | 06f61b2fd72bc41627fc3375161df84c2674d29b (patch) | |
tree | 7df19832a66b187f421275411efbce3c88d15112 | |
parent | cmake: slight CMakeLists.txt refactoring (diff) | |
download | winapi-debug-06f61b2fd72bc41627fc3375161df84c2674d29b.tar.gz winapi-debug-06f61b2fd72bc41627fc3375161df84c2674d29b.zip |
cmake: check CTest tests output
Diffstat (limited to '')
m--------- | cmake | 0 | ||||
-rw-r--r-- | test/CMakeLists.txt | 9 | ||||
-rw-r--r-- | utils/CMakeLists.txt | 10 |
3 files changed, 17 insertions, 2 deletions
diff --git a/cmake b/cmake -Subproject e5de0b18453dd2fb3bf3e02414ee00ee185d81d +Subproject 2a12d269f75b96cedc2615dc410bdd067fd3548 diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 87697fe..3b415a8 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -12,6 +12,13 @@ target_link_libraries(call_stack PRIVATE Boost::nowide) install(TARGETS call_stack RUNTIME DESTINATION bin/test) install_pdbs(TARGETS call_stack DESTINATION bin/test) -add_test(NAME call_stack COMMAND call_stack) +find_package(Python3 REQUIRED COMPONENTS Interpreter) + +add_test(NAME call_stack COMMAND Python3::Interpreter + "${CMAKE_CURRENT_SOURCE_DIR}/../cmake/tools/ctest-driver.py" + run + --pass-regex test_ns::baz test_ns::bar test_ns::foo + -- + "$<TARGET_FILE:call_stack>") add_subdirectory(unit_tests) diff --git a/utils/CMakeLists.txt b/utils/CMakeLists.txt index 6f469a8..6a345c9 100644 --- a/utils/CMakeLists.txt +++ b/utils/CMakeLists.txt @@ -13,5 +13,13 @@ add_util(name2addr name2addr.cpp) add_util(addr2name addr2name.cpp command_line.hpp pdb_descr.hpp) if(MSVC) - add_test(NAME enum_symbols COMMAND enum_symbols --pdb "$<TARGET_PDB_FILE:test_lib>" --mask "test_ns:*") + find_package(Python3 REQUIRED COMPONENTS Interpreter) + add_test(NAME enum_symbols COMMAND Python3::Interpreter + "${CMAKE_CURRENT_SOURCE_DIR}/../cmake/tools/ctest-driver.py" + run + --pass-regex test_ns::baz test_ns::bar test_ns::foo test_ns::var + -- + "$<TARGET_FILE:enum_symbols>" + --pdb "$<TARGET_PDB_FILE:test_lib>" + --mask "test_ns:*") endif() |