1 |
|
include(FindPerl) |
2 |
|
|
3 |
|
set(resources_dir "${CMAKE_SOURCE_DIR}/resources") |
4 |
+ |
set(rad_test_dir "${CMAKE_SOURCE_DIR}/test") |
5 |
|
|
6 |
+ |
### CONFIGURE TESTS |
7 |
+ |
|
8 |
|
configure_file(setup_paths.cmake.in setup_paths.cmake @ONLY) |
9 |
|
# configure these files so that they will be in the binary |
10 |
|
# directory. This will allow them to include setup_paths.cmake |
13 |
|
configure_file(test_setup.cmake test_setup.cmake COPYONLY) |
14 |
|
configure_file(test_rtrace.cmake test_rtrace.cmake COPYONLY) |
15 |
|
configure_file(test_rpict.cmake test_rpict.cmake COPYONLY) |
13 |
– |
configure_file(test_getinfo.cmake test_getinfo.cmake COPYONLY) |
16 |
|
configure_file(test_pcond.cmake test_pcond.cmake COPYONLY) |
17 |
|
configure_file(test_falsecolor.cmake test_falsecolor.cmake COPYONLY) |
18 |
|
configure_file(test_DC.cmake test_DC.cmake COPYONLY) |
19 |
|
configure_file(test_evalglare.cmake test_evalglare.cmake COPYONLY) |
20 |
|
|
21 |
+ |
### ADD TESTS |
22 |
+ |
|
23 |
|
add_test(test_setup ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/test_setup.cmake) |
24 |
|
|
25 |
|
add_test(test_rtrace ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/test_rtrace.cmake) |
34 |
|
FAIL_REGULAR_EXPRESSION "failed" |
35 |
|
) |
36 |
|
|
33 |
– |
add_test(test_getinfo ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/test_getinfo.cmake) |
34 |
– |
|
37 |
|
add_test(test_pcond ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/test_pcond.cmake) |
38 |
|
set_tests_properties(test_pcond PROPERTIES |
39 |
|
PASS_REGULAR_EXPRESSION "passed" |
45 |
|
PASS_REGULAR_EXPRESSION "passed" |
46 |
|
FAIL_REGULAR_EXPRESSION "failed" |
47 |
|
) |
48 |
+ |
|
49 |
|
|
50 |
|
if(PERL_FOUND) |
51 |
|
add_test(test_falsecolor ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/test_falsecolor.cmake) |