2018-03-22 18:11:39 +01:00
|
|
|
# Copy h5 files to binary dir
|
2019-04-03 00:07:03 +02:00
|
|
|
file(GLOB_RECURSE all_h5_ref_files RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.ref.h5)
|
|
|
|
foreach(file ${all_h5_ref_files})
|
|
|
|
configure_file(${file} ${file} COPYONLY)
|
|
|
|
endforeach()
|
2018-03-22 18:11:39 +01:00
|
|
|
|
2019-04-03 00:07:03 +02:00
|
|
|
# List of all tests
|
2018-03-22 18:11:39 +01:00
|
|
|
set(all_tests Toto chain)
|
|
|
|
|
2019-04-03 00:07:03 +02:00
|
|
|
foreach(test ${all_tests})
|
|
|
|
get_filename_component(test_name ${test} NAME_WE)
|
|
|
|
get_filename_component(test_dir ${test} DIRECTORY)
|
2019-04-12 23:54:14 +02:00
|
|
|
add_test(NAME ${test_name} COMMAND ${TRIQS_PYTHON_INTERPRETER} ${CMAKE_CURRENT_SOURCE_DIR}/${test_dir}/${test_name}.py WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/${test_dir})
|
2019-04-03 00:07:03 +02:00
|
|
|
set_property(TEST ${test_name} APPEND PROPERTY ENVIRONMENT PYTHONPATH=${CMAKE_BINARY_DIR}/python:$ENV{PYTHONPATH} ${SANITIZER_RT_PRELOAD})
|
2018-03-22 18:11:39 +01:00
|
|
|
endforeach()
|