Skip to content

Commit

Permalink
cmake: Use generated tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jorisv committed Jan 30, 2024
1 parent 7c39cd8 commit b8004fe
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 136 deletions.
7 changes: 5 additions & 2 deletions unittest/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,11 @@ function(config_test test tagname opttype)
configure_file(python/test_${test}.py.in
${CMAKE_CURRENT_BINARY_DIR}/python/${py_file})
add_lib_unit_test(${MODNAME})
add_python_unit_test("py-${test}-${tagname}" "unittest/python/${py_file}"
"unittest")
set(PYTHON_TEST_NAME "py-${test}-${tagname}")
add_test(NAME ${PYTHON_TEST_NAME}
COMMAND ${PYTHON_EXECUTABLE} "${CMAKE_CURRENT_BINARY_DIR}/python/${py_file}")
compute_pythonpath(ENV_VARIABLES "unittest")
set_tests_properties(${PYTHON_TEST_NAME} PROPERTIES ENVIRONMENT "${ENV_VARIABLES}")
endfunction()

config_test(variant boost "boost::variant")
Expand Down
67 changes: 0 additions & 67 deletions unittest/python/test_optional_boost.py

This file was deleted.

67 changes: 0 additions & 67 deletions unittest/python/test_optional_std.py

This file was deleted.

0 comments on commit b8004fe

Please sign in to comment.