CMakeLists.txt 4.6 KB
Newer Older
Dennis Gläser's avatar
Dennis Gläser committed
1
dune_symlink_to_source_files(FILES "test_2p.input")
2

Dennis Gläser's avatar
Dennis Gläser committed
3
# using tpfa
4
5
6
add_executable(test_2p_incompressible_tpfa EXCLUDE_FROM_ALL test_2p_fv.cc)
target_compile_definitions(test_2p_incompressible_tpfa PUBLIC TYPETAG=TwoPIncompressibleTpfa)

Dennis Gläser's avatar
Dennis Gläser committed
7
dune_add_test(NAME test_2p_incompressible_tpfa
8
              TARGET test_2p_incompressible_tpfa
9
10
11
12
13
              COMMAND ${CMAKE_SOURCE_DIR}/bin/testing/runtest.py
              CMD_ARGS --script fuzzy
                       --files ${CMAKE_SOURCE_DIR}/test/references/lenscc-reference.vtu
                               ${CMAKE_CURRENT_BINARY_DIR}/2p_tpfa-00008.vtu
                       --command "${CMAKE_CURRENT_BINARY_DIR}/test_2p_incompressible_tpfa test_2p.input -Problem.Name 2p_tpfa")
14

15
16
# using tpfa
dune_add_test(NAME test_2p_incompressible_tpfa_restart
17
              TARGET test_2p_incompressible_tpfa
18
19
20
21
              COMMAND ${CMAKE_SOURCE_DIR}/bin/testing/runtest.py
              CMD_ARGS --script fuzzy
                       --files ${CMAKE_SOURCE_DIR}/test/references/lenscc-reference.vtu
                               ${CMAKE_CURRENT_BINARY_DIR}/2p_tpfa_restart-00003.vtu
22
                       --command "${CMAKE_CURRENT_BINARY_DIR}/test_2p_incompressible_tpfa test_2p.input -Problem.Name 2p_tpfa_restart  -TimeLoop.DtInitial 526.62 -Restart.Time 1859.95 -Restart.File 2p_tpfa-00005.vtu")
23

24
25
26
# the restart test has to run after the test that produces the corresponding vtu file
set_tests_properties(test_2p_incompressible_tpfa_restart PROPERTIES DEPENDS test_2p_incompressible_tpfa)

Dennis Gläser's avatar
Dennis Gläser committed
27
28
# using box
dune_add_test(NAME test_2p_incompressible_box
29
30
              SOURCES test_2p_fv.cc
              COMPILE_DEFINITIONS TYPETAG=TwoPIncompressibleBox
31
32
33
34
35
              COMMAND ${CMAKE_SOURCE_DIR}/bin/testing/runtest.py
              CMD_ARGS --script fuzzy
                       --files ${CMAKE_SOURCE_DIR}/test/references/lensbox-reference.vtu
                               ${CMAKE_CURRENT_BINARY_DIR}/2p_box-00007.vtu
                       --command "${CMAKE_CURRENT_BINARY_DIR}/test_2p_incompressible_box test_2p.input -Problem.Name 2p_box")
Dennis Gläser's avatar
Dennis Gläser committed
36

37
38
39
40
41
42
43
44
45
46
47
# using box with interface solver
dune_add_test(NAME test_2p_incompressible_box_ifsolver
              SOURCES test_2p_fv.cc
              COMPILE_DEFINITIONS TYPETAG=TwoPIncompressibleBox
              COMPILE_DEFINITIONS ENABLEINTERFACESOLVER=true
              COMMAND ${CMAKE_SOURCE_DIR}/bin/testing/runtest.py
              CMD_ARGS --script fuzzy
                       --files ${CMAKE_SOURCE_DIR}/test/references/lensbox_ifsolver-reference.vtu
                               ${CMAKE_CURRENT_BINARY_DIR}/2p_box_ifsolver-00018.vtu
                       --command "${CMAKE_CURRENT_BINARY_DIR}/test_2p_incompressible_box_ifsolver test_2p.input
                                                                                                  -Problem.Name 2p_box_ifsolver
48
49
50
51
52
53
54
55
56
57
58
59
60
61
                                                                                                  -Problem.UseNonConformingOutput true")

# using tpfa with an oil-wet lens
dune_add_test(NAME test_2p_incompressible_tpfa_oilwet
              SOURCES test_2p_fv.cc
              COMPILE_DEFINITIONS TYPETAG=TwoPIncompressibleTpfa
              COMMAND ${CMAKE_SOURCE_DIR}/bin/testing/runtest.py
              CMD_ARGS --script fuzzy
                       --files ${CMAKE_SOURCE_DIR}/test/references/lenscc_oilwet-reference.vtu
                               ${CMAKE_CURRENT_BINARY_DIR}/2p_tpfa_oilwet-00009.vtu
                       --command "${CMAKE_CURRENT_BINARY_DIR}/test_2p_incompressible_tpfa_oilwet test_2p.input
                                                                                                 -Problem.Name 2p_tpfa_oilwet
                                                                                                 -Problem.EnableGravity false
                                                                                                 -SpatialParams.LensIsOilWet true")
62

63
64
# using mpfa
dune_add_test(NAME test_2p_incompressible_mpfa
65
              SOURCES test_2p_fv.cc
66
              COMPILE_DEFINITIONS TYPETAG=TwoPIncompressibleMpfa
67
68
69
70
71
              COMMAND ${CMAKE_SOURCE_DIR}/bin/testing/runtest.py
              CMD_ARGS --script fuzzy
                       --files ${CMAKE_SOURCE_DIR}/test/references/lenscc-reference.vtu
                               ${CMAKE_CURRENT_BINARY_DIR}/2p_mpfa-00008.vtu
                       --command "${CMAKE_CURRENT_BINARY_DIR}/test_2p_incompressible_mpfa test_2p.input -Problem.Name 2p_mpfa")
72

Dennis Gläser's avatar
Dennis Gläser committed
73
set(CMAKE_BUILD_TYPE Release)
74
75
76
77
78

#install sources
install(FILES
problem.hh
spatialparams.hh
79
test_2p_fv.cc
80
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/dumux/test/implicit/2p/incompressible)