Skip to content
Snippets Groups Projects
Commit 034e0777 authored by Pospelov, Gennady's avatar Pospelov, Gennady
Browse files

Script to check Python examples now takes from CMake location of libraries

parent dc7104bc
No related branches found
No related tags found
No related merge requests found
......@@ -6,12 +6,13 @@
#
###############################################################################
add_custom_target(TempQtCreatorTarget SOURCES check_functionality.py)
# add_custom_target(TempQtCreatorTarget SOURCES check_functionality.py)
file(GLOB examples "${PY_EXAMPLES_DIR}/simulation/ex*/*.py")
set(test_script ${CMAKE_SOURCE_DIR}/Tests/Functional/PyExamples/check_functionality.py)
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/check_functionality.py ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/check_functionality.py @ONLY)
set(test_script ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/check_functionality.py)
foreach(example ${examples})
set(script_path ${example})
......@@ -21,4 +22,3 @@ foreach(example ${examples})
add_test(${test_name} ${PYTHON_EXECUTABLE} ${test_script} ${script_path})
set_tests_properties(${test_name} PROPERTIES LABELS "Examples")
endforeach()
......@@ -13,6 +13,7 @@ import matplotlib
matplotlib.use('Agg')
from matplotlib import pyplot as plt
sys.path.append("@CMAKE_LIBRARY_OUTPUT_DIRECTORY@")
def get_figure(filename):
"""
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment