From b4d6e7e095603d55a89bd3cd8e9ff1db03eed446 Mon Sep 17 00:00:00 2001 From: Elias Pipping <elias.pipping@fu-berlin.de> Date: Tue, 22 Sep 2015 13:02:58 +0200 Subject: [PATCH] Actually use UG I only just now noticed that none of the tests in question was testing anything for me. Both Alugrid and UG are considered acceptable grid providers but if neither is viewed as found in the test (be it because you really don't have them installed or because the build system doesn't pass on the information properly (fixed!)), then the tests pass without testing anything. std::cout and std::cerr output from the individual tests is discarded by the make test routine, so it's not trivial to warn the user (or rather developer) about this. --- dune/solvers/test/CMakeLists.txt | 22 +++++++++++++++++----- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git a/dune/solvers/test/CMakeLists.txt b/dune/solvers/test/CMakeLists.txt index 4b370037..74c87a82 100644 --- a/dune/solvers/test/CMakeLists.txt +++ b/dune/solvers/test/CMakeLists.txt @@ -1,20 +1,25 @@ -set(TESTS +set(GRID_BASED_TESTS cgsteptest + multigridtest + projectedgradienttest + obstacletnnmgtest + ) + +set(OTHER_TESTS genericvectortoolstest lowrankoperatortest - multigridtest nulloperatortest - obstacletnnmgtest - projectedgradienttest sumoperatortest ) set(TESTS_IPOPT mmgtest quadraticipoptsolvertest) if(HAVE_IPOPT) - list(APPEND TESTS ${TESTS_IPOPT}) + list(APPEND GRID_BASED_TESTS ${TESTS_IPOPT}) endif() +set(TESTS ${OTHER_TESTS} ${GRID_BASED_TESTS}) + foreach(_test ${TESTS}) add_executable(${_test} EXCLUDE_FROM_ALL ${_test}.cc) target_link_dune_default_libraries(${_test}) @@ -27,5 +32,12 @@ if(HAVE_IPOPT) endforeach() endif() +# Add external grid manager flags +foreach(_test ${GRID_BASED_TESTS}) + if(HAVE_UG) + add_dune_ug_flags(${_test}) + endif(HAVE_UG) +endforeach() + add_directory_test_target(_test_target) add_dependencies(${_test_target} ${TESTS}) -- GitLab