CMakeLists.txt 1.49 KB
Newer Older
1
add_executable("test_box3p3c" EXCLUDE_FROM_ALL test_box3p3c.cc)
Christoph Grueninger's avatar
Christoph Grueninger committed
2
3
4
5
6
7
8
9
10
11
12
add_test(test_box3p3c
  ${CMAKE_SOURCE_DIR}/bin/runTest.sh
  ${CMAKE_SOURCE_DIR}/bin/fuzzycomparevtu.py
  ${CMAKE_SOURCE_DIR}/test/references/infiltrationbox-reference.vtu
  ${CMAKE_CURRENT_BINARY_DIR}/infiltrationbox-00007.vtu
  ${CMAKE_CURRENT_BINARY_DIR}/test_box3p3c
  -ParameterFile ${CMAKE_CURRENT_SOURCE_DIR}/test_box3p3c.input
  -Grid.File ${CMAKE_CURRENT_SOURCE_DIR}/grids/test_3p3c_coarse.dgf
  -TimeManager.TEnd 8.64e5
  -TimeManager.DtInitial 8.64e4)

13
add_executable("test_cc3p3c" EXCLUDE_FROM_ALL test_cc3p3c.cc)
Christoph Grueninger's avatar
Christoph Grueninger committed
14
15
16
17
18
19
20
21
22
23
24
add_test(test_cc3p3c
  ${CMAKE_SOURCE_DIR}/bin/runTest.sh
  ${CMAKE_SOURCE_DIR}/bin/fuzzycomparevtu.py
  ${CMAKE_SOURCE_DIR}/test/references/infiltrationcc-reference.vtu
  ${CMAKE_CURRENT_BINARY_DIR}/infiltrationcc-00006.vtu
  ${CMAKE_CURRENT_BINARY_DIR}/test_cc3p3c
  -ParameterFile ${CMAKE_CURRENT_SOURCE_DIR}/test_cc3p3c.input
  -Grid.File ${CMAKE_CURRENT_SOURCE_DIR}/grids/test_3p3c_coarse.dgf
  -TimeManager.TEnd 8.64e5
  -TimeManager.DtInitial 8.64e4)

25

26
27
28
29
set(NORMALTESTS
  test_box3p3c
  test_cc3p3c)
set(ALLTESTS ${NORMALTESTS})
30

31
32
33
34
# We do not want want to build the tests during make all,
# but just build them on demand
add_directory_test_target(_test_target)
add_dependencies(${_test_target} ${ALLTESTS})
35
36
set_property(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
  PROPERTY TEST_INCLUDE_FILE ${CMAKE_CURRENT_BINARY_DIR}/BuildTests.cmake)
37

38
39
40
foreach(_exe ${ALLTESTS})
  target_link_libraries(${_exe} ${DUNE_LIBS})
endforeach(_exe ${ALLTESTS})