Files
ortools-clone/examples/python/CMakeLists.txt
Corentin Le Molgat 8bd5acee1a Add Test & Examples
Tests:
- Add cc test
- Add python test

Examples:
- Add examples/cpp
- Add examples/data
- Add examples/notebook
- Add examples/python

Signed-off-by: Corentin Le Molgat <corentinl@google.com>
2018-01-19 15:03:25 +01:00

21 lines
459 B
CMake

if (NOT BUILD_PYTHON)
return()
endif()
foreach(TEST
hidato_table
integer_programming
knapsack
linear_programming
pyflow_example
tsp
)
add_test(py${TEST}_venv ${VENV_BIN_DIR}/python ${CMAKE_CURRENT_SOURCE_DIR}/${TEST}.py)
set_tests_properties(py${TEST}_venv PROPERTIES DEPENDS build_venv)
endforeach()
include(GNUInstallDirs)
install(DIRECTORY .
DESTINATION ${CMAKE_INSTALL_DATADIR}/ortools/examples/python
FILES_MATCHING PATTERN "*.py")