From b4be4fb9aa089295aa35445c9f48bee987db290c Mon Sep 17 00:00:00 2001 From: Christoph Grueninger <christoph.grueninger@iws.uni-stuttgart.de> Date: Tue, 21 Jul 2015 13:45:17 +0000 Subject: [PATCH] Add warning and output for every skipped test. (reviewed by timok) git-svn-id: svn://svn.iws.uni-stuttgart.de/DUMUX/dumux/trunk@15127 2fb0f335-1f38-0410-981e-8018bf24f1b0 --- test/decoupled/1p/test_diffusion3d.cc | 6 ++---- test/decoupled/2p/test_3d2p.cc | 6 ++---- test/decoupled/2p/test_impesadaptive.cc | 5 ++--- test/decoupled/2p/test_mpfa2p.cc | 6 ++---- test/decoupled/2p2c/test_adaptive2p2c2d.cc | 2 +- test/decoupled/2p2c/test_adaptive2p2c3d.cc | 5 ++--- test/freeflow/navierstokes/test_navierstokes.cc | 4 ++-- test/geomechanics/el2p/test_el2p.cc | 3 +-- test/implicit/1p/test_box1p1d3d.cc | 3 ++- test/implicit/1p/test_box1p2d3d.cc | 3 ++- test/implicit/1p/test_cc1p1d3d.cc | 3 ++- test/implicit/1p/test_cc1p2d3d.cc | 3 ++- test/implicit/2p/test_boxadaptive2p.cc | 2 ++ test/implicit/2p/test_ccadaptive2p.cc | 2 ++ test/implicit/2pdfm/test_2pdfm.cc | 5 ++--- test/implicit/co2/test_boxco2.cc | 6 ++++-- test/implicit/co2/test_boxco2ni.cc | 6 ++++-- test/implicit/co2/test_ccco2.cc | 6 ++++-- test/implicit/co2/test_ccco2ni.cc | 6 ++++-- test/implicit/mpnc/test_boxmpnckinetic.cc | 3 ++- test/implicit/mpnc/test_boxmpncthermalnonequil.cc | 3 ++- test/multidomain/2cnistokes2p2cni/test_2cnistokes2p2cni.cc | 6 ++---- test/multidomain/2cnizeroeq2p2cni/test_2cnizeroeq2p2cni.cc | 5 +---- test/multidomain/2cstokes2p2c/test_2cstokes2p2c.cc | 7 ++----- test/multidomain/2czeroeq2p2c/test_2czeroeq2p2c.cc | 7 ++----- 25 files changed, 55 insertions(+), 58 deletions(-) diff --git a/test/decoupled/1p/test_diffusion3d.cc b/test/decoupled/1p/test_diffusion3d.cc index 69ef727d1d..fad45f6d5a 100644 --- a/test/decoupled/1p/test_diffusion3d.cc +++ b/test/decoupled/1p/test_diffusion3d.cc @@ -225,12 +225,10 @@ int main(int argc, char** argv) return 3; } #else - -#warning You need to have ALUGrid or UG installed to run this test - int main() { - std::cerr << "You need to have ALUGrid or UG installed to run this test\n"; +#warning You need to have dune-ALUGrid or UG installed to run this test + std::cerr << "You need to have dune-ALUGrid or UG installed to run this test\n"; return 77; } #endif // HAVE_ALUGRID || HAVE_DUNE_ALUGRID || HAVE_UG diff --git a/test/decoupled/2p/test_3d2p.cc b/test/decoupled/2p/test_3d2p.cc index 1c77df7a12..1ce5d767b7 100644 --- a/test/decoupled/2p/test_3d2p.cc +++ b/test/decoupled/2p/test_3d2p.cc @@ -177,14 +177,12 @@ int main(int argc, char** argv) #else -#warning You need to have ALUGrid installed to run this test - #include <iostream> int main() { - std::cerr << "You need to have ALUGrid installed to run this test\n"; +#warning You need to have dune-ALUGrid installed to run this test + std::cerr << "You need to have dune-ALUGrid installed to run this test\n"; return 77; } - #endif diff --git a/test/decoupled/2p/test_impesadaptive.cc b/test/decoupled/2p/test_impesadaptive.cc index 7de73df93a..993eb575b8 100644 --- a/test/decoupled/2p/test_impesadaptive.cc +++ b/test/decoupled/2p/test_impesadaptive.cc @@ -58,13 +58,12 @@ int main(int argc, char** argv) } #else -#warning You need to have ALUGrid installed to run this test - #include <iostream> int main() { - std::cerr << "You need to have ALUGrid installed to run this test\n"; +#warning You need to have dune-ALUGrid installed to run this test + std::cerr << "You need to have dune-ALUGrid installed to run this test\n"; return 77; } #endif // HAVE_ALUGRID diff --git a/test/decoupled/2p/test_mpfa2p.cc b/test/decoupled/2p/test_mpfa2p.cc index 13b0581883..0029b8afa1 100644 --- a/test/decoupled/2p/test_mpfa2p.cc +++ b/test/decoupled/2p/test_mpfa2p.cc @@ -151,14 +151,12 @@ int main(int argc, char** argv) #else -#warning You need to have ALUGrid installed to run this test - #include <iostream> int main() { - std::cerr << "You need to have ALUGrid installed to run this test\n"; +#warning You need to have dune-ALUGrid installed to run this test + std::cerr << "You need to have dune-ALUGrid installed to run this test\n"; return 77; } - #endif diff --git a/test/decoupled/2p2c/test_adaptive2p2c2d.cc b/test/decoupled/2p2c/test_adaptive2p2c2d.cc index ccdc51cabb..e69f60615a 100644 --- a/test/decoupled/2p2c/test_adaptive2p2c2d.cc +++ b/test/decoupled/2p2c/test_adaptive2p2c2d.cc @@ -60,7 +60,7 @@ int main(int argc, char** argv) return Dumux::start<TypeTag>(argc, argv, usage); #else #warning ALUGrid needed for this test. - std::cout << "ALUGrid needed for this test. Aborting." << std::endl; + std::cerr << "ALUGrid needed for this test. Aborting." << std::endl; return 77; #endif } diff --git a/test/decoupled/2p2c/test_adaptive2p2c3d.cc b/test/decoupled/2p2c/test_adaptive2p2c3d.cc index d372c08ca2..4c35be3f83 100644 --- a/test/decoupled/2p2c/test_adaptive2p2c3d.cc +++ b/test/decoupled/2p2c/test_adaptive2p2c3d.cc @@ -63,13 +63,12 @@ int main(int argc, char** argv) #else -#warning You need to have ALUGrid installed to run this test - #include <iostream> int main() { - std::cerr << "You need to have ALUGrid installed to run this test\n"; +#warning You need to have dune-ALUGrid installed to run this test + std::cerr << "You need to have dune-ALUGrid installed to run this test\n"; return 77; } #endif // HAVE_ALUGRID || HAVE_DUNE_ALUGRID diff --git a/test/freeflow/navierstokes/test_navierstokes.cc b/test/freeflow/navierstokes/test_navierstokes.cc index 7bb7e20163..c77ff0ae6d 100644 --- a/test/freeflow/navierstokes/test_navierstokes.cc +++ b/test/freeflow/navierstokes/test_navierstokes.cc @@ -55,8 +55,8 @@ int main(int argc, char** argv) typedef TTAG(NavierStokesTestProblem) ProblemTypeTag; return Dumux::start<ProblemTypeTag>(argc, argv, usage); #else -#warning "You need to have SuperLU and ALUGrid or UG to run this test." - std::cout << "You need to have SuperLU and ALUGrid or UG to run this test." << std::endl; +#warning "You need to have SuperLU and dune-ALUGrid or UG to run this test." + std::cerr << "You need to have SuperLU and dune-ALUGrid or UG to run this test." << std::endl; return 77; #endif } diff --git a/test/geomechanics/el2p/test_el2p.cc b/test/geomechanics/el2p/test_el2p.cc index f59c6d8afa..ccfa4e1102 100644 --- a/test/geomechanics/el2p/test_el2p.cc +++ b/test/geomechanics/el2p/test_el2p.cc @@ -104,12 +104,11 @@ int main(int argc, char** argv) { #else // HAVE_DUNE_PDELAB -#warning You need to have dune-pdelab (>= 2.0) installed to run this test. - #include <iostream> int main() { +#warning You need to have dune-pdelab (>= 2.0) installed to run this test. std::cerr << "You need to have dune-pdelab (>= 2.0) installed to run this test.\n"; return 77; } diff --git a/test/implicit/1p/test_box1p1d3d.cc b/test/implicit/1p/test_box1p1d3d.cc index 79f3611b1f..cde671079d 100644 --- a/test/implicit/1p/test_box1p1d3d.cc +++ b/test/implicit/1p/test_box1p1d3d.cc @@ -63,7 +63,8 @@ int main(int argc, char** argv) typedef TTAG(OnePOneDThreeDTestBoxProblem) ProblemTypeTag; return Dumux::start<ProblemTypeTag>(argc, argv, usage); #else - std::cout << "Test skipped, it needs Alberta!" << std::endl; +#warning External grid Alberta needed to run this example. + std::cerr << "Test skipped, it needs Alberta!" << std::endl; return 77; #endif } diff --git a/test/implicit/1p/test_box1p2d3d.cc b/test/implicit/1p/test_box1p2d3d.cc index b66d95cfdf..bca74640c9 100644 --- a/test/implicit/1p/test_box1p2d3d.cc +++ b/test/implicit/1p/test_box1p2d3d.cc @@ -63,7 +63,8 @@ int main(int argc, char** argv) typedef TTAG(OnePTwoDThreeDTestBoxProblem) ProblemTypeTag; return Dumux::start<ProblemTypeTag>(argc, argv, usage); #else - std::cout << "Test skipped, it needs Alberta!" << std::endl; +#warning External grid Alberta needed to run this example. + std::cerr << "Test skipped, it needs Alberta!" << std::endl; return 77; #endif } diff --git a/test/implicit/1p/test_cc1p1d3d.cc b/test/implicit/1p/test_cc1p1d3d.cc index 6502e9f9d0..46fed9ad11 100644 --- a/test/implicit/1p/test_cc1p1d3d.cc +++ b/test/implicit/1p/test_cc1p1d3d.cc @@ -63,7 +63,8 @@ int main(int argc, char** argv) typedef TTAG(OnePOneDThreeDTestCCProblem) ProblemTypeTag; return Dumux::start<ProblemTypeTag>(argc, argv, usage); #else - std::cout << "Test skipped, it needs Alberta!" << std::endl; +#warning External grid Alberta needed to run this example. + std::cerr << "Test skipped, it needs Alberta!" << std::endl; return 77; #endif } diff --git a/test/implicit/1p/test_cc1p2d3d.cc b/test/implicit/1p/test_cc1p2d3d.cc index 9a3725b7e1..813ec03aff 100644 --- a/test/implicit/1p/test_cc1p2d3d.cc +++ b/test/implicit/1p/test_cc1p2d3d.cc @@ -63,7 +63,8 @@ int main(int argc, char** argv) typedef TTAG(OnePTwoDThreeDTestCCProblem) ProblemTypeTag; return Dumux::start<ProblemTypeTag>(argc, argv, usage); #else - std::cout << "Test skipped, it needs Alberta!" << std::endl; +#warning External grid Alberta needed to run this example. + std::cerr << "Test skipped, it needs Alberta!" << std::endl; return 77; #endif } diff --git a/test/implicit/2p/test_boxadaptive2p.cc b/test/implicit/2p/test_boxadaptive2p.cc index 39170d1a33..2fa8128337 100644 --- a/test/implicit/2p/test_boxadaptive2p.cc +++ b/test/implicit/2p/test_boxadaptive2p.cc @@ -65,6 +65,8 @@ int main(int argc, char** argv) typedef TTAG(LensBoxAdaptiveProblem) TypeTag; return Dumux::start<TypeTag>(argc, argv, usage); #else +#warning You need dune-ALUGrid to run this test. + std::cerr << "You need dune-ALUGrid to run this test." << std::endl; return 77; #endif } diff --git a/test/implicit/2p/test_ccadaptive2p.cc b/test/implicit/2p/test_ccadaptive2p.cc index 2a0ffe641c..639c50e43e 100644 --- a/test/implicit/2p/test_ccadaptive2p.cc +++ b/test/implicit/2p/test_ccadaptive2p.cc @@ -66,6 +66,8 @@ int main(int argc, char** argv) typedef TTAG(LensCCAdaptiveProblem) TypeTag; return Dumux::start<TypeTag>(argc, argv, usage); #else +#warning You need dune-ALUGrid to run this test. + std::cerr << "You need dune-ALUGrid to run this test." << std::endl; return 77; #endif diff --git a/test/implicit/2pdfm/test_2pdfm.cc b/test/implicit/2pdfm/test_2pdfm.cc index bf18b00a41..357c7feebd 100644 --- a/test/implicit/2pdfm/test_2pdfm.cc +++ b/test/implicit/2pdfm/test_2pdfm.cc @@ -62,11 +62,10 @@ int main(int argc, char** argv) } #else // HAVE_UG - int main(int argc, char** argv) { - std::cout << "External grid UG needed to run this example." << std::endl; +#warning External grid UG needed to run this example. + std::cerr << "External grid UG needed to run this example." << std::endl; return 77; } - #endif // HAVE_UG \ No newline at end of file diff --git a/test/implicit/co2/test_boxco2.cc b/test/implicit/co2/test_boxco2.cc index 833b660a6d..b992b93c18 100644 --- a/test/implicit/co2/test_boxco2.cc +++ b/test/implicit/co2/test_boxco2.cc @@ -67,10 +67,12 @@ void usage(const char *progName, const std::string &errorMsg) int main(int argc, char** argv) { #if !DUNE_GRID_EXPERIMENTAL_GRID_EXTENSIONS - std::cout << "Test skipped, it needs experimental grid extensions, see optim.opts or debug.opts." << std::endl; +#warning Test needs experimental grid extensions. + std::cerr << "Test skipped, it needs experimental grid extensions, see optim.opts or debug.opts." << std::endl; return 77; #elif !(HAVE_ALUGRID || HAVE_DUNE_ALUGRID) - std::cout << "Test skipped, it needs ALUGrid, see optim.opts or debug.opts." << std::endl; +#warning You need to have dune-ALUGrid installed to run this test. + std::cerr << "You need to have dune-ALUGrid installed to run this test." << std::endl; return 77; #else typedef TTAG(HeterogeneousBoxProblem) ProblemTypeTag; diff --git a/test/implicit/co2/test_boxco2ni.cc b/test/implicit/co2/test_boxco2ni.cc index df9b4f940f..86004ef004 100644 --- a/test/implicit/co2/test_boxco2ni.cc +++ b/test/implicit/co2/test_boxco2ni.cc @@ -68,10 +68,12 @@ void usage(const char *progName, const std::string &errorMsg) int main(int argc, char** argv) { #if !DUNE_GRID_EXPERIMENTAL_GRID_EXTENSIONS - std::cout << "Test skipped, it needs experimental grid extensions, see optim.opts or debug.opts." << std::endl; +#warning Test needs experimental grid extensions. + std::cerr << "Test skipped, it needs experimental grid extensions, see optim.opts or debug.opts." << std::endl; return 77; #elif !(HAVE_ALUGRID || HAVE_DUNE_ALUGRID) - std::cout << "Test skipped, it needs ALUGrid, see optim.opts or debug.opts." << std::endl; +#warning You need to have dune-ALUGrid installed to run this test. + std::cerr << "You need to have dune-ALUGrid installed to run this test." << std::endl; return 77; #else typedef TTAG(HeterogeneousNIBoxProblem) ProblemTypeTag; diff --git a/test/implicit/co2/test_ccco2.cc b/test/implicit/co2/test_ccco2.cc index 92ea99db7d..b3eacc9a74 100644 --- a/test/implicit/co2/test_ccco2.cc +++ b/test/implicit/co2/test_ccco2.cc @@ -67,10 +67,12 @@ void usage(const char *progName, const std::string &errorMsg) int main(int argc, char** argv) { #if !DUNE_GRID_EXPERIMENTAL_GRID_EXTENSIONS - std::cout << "Test skipped, it needs experimental grid extensions, see optim.opts or debug.opts." << std::endl; +#warning Test needs experimental grid extensions. + std::cerr << "Test skipped, it needs experimental grid extensions, see optim.opts or debug.opts." << std::endl; return 77; #elif !(HAVE_ALUGRID || HAVE_DUNE_ALUGRID) - std::cout << "Test skipped, it needs ALUGrid, see optim.opts or debug.opts." << std::endl; +#warning You need to have dune-ALUGrid installed to run this test. + std::cerr << "You need to have dune-ALUGrid installed to run this test." << std::endl; return 77; #else typedef TTAG(HeterogeneousCCProblem) ProblemTypeTag; diff --git a/test/implicit/co2/test_ccco2ni.cc b/test/implicit/co2/test_ccco2ni.cc index d6e50fdba8..e7e591ab3a 100644 --- a/test/implicit/co2/test_ccco2ni.cc +++ b/test/implicit/co2/test_ccco2ni.cc @@ -68,10 +68,12 @@ void usage(const char *progName, const std::string &errorMsg) int main(int argc, char** argv) { #if !DUNE_GRID_EXPERIMENTAL_GRID_EXTENSIONS - std::cout << "Test skipped, it needs experimental grid extensions, see optim.opts or debug.opts." << std::endl; +#warning Test needs experimental grid extensions. + std::cerr << "Test skipped, it needs experimental grid extensions, see optim.opts or debug.opts." << std::endl; return 77; #elif !(HAVE_ALUGRID || HAVE_DUNE_ALUGRID) - std::cout << "Test skipped, it needs ALUGrid, see optim.opts or debug.opts." << std::endl; +#warning You need to have dune-ALUGrid installed to run this test. + std::cerr << "You need to have dune-ALUGrid installed to run this test." << std::endl; return 77; #else typedef TTAG(HeterogeneousNICCProblem) ProblemTypeTag; diff --git a/test/implicit/mpnc/test_boxmpnckinetic.cc b/test/implicit/mpnc/test_boxmpnckinetic.cc index 9327bc90ac..d1dccc42b6 100644 --- a/test/implicit/mpnc/test_boxmpnckinetic.cc +++ b/test/implicit/mpnc/test_boxmpnckinetic.cc @@ -257,7 +257,8 @@ int start(int argc, char **argv) int main(int argc, char** argv) { #if !HAVE_UG && !(HAVE_ALUGRID || HAVE_DUNE_ALUGRID) - std::cout<<"Evaporation Atmosphere not built, needs either UG or ALU for the log mesh." << std::endl; +#warning Evaporation Atmosphere not built, needs either UG or dune-ALUGrid for the log mesh. + std::cerr << "Evaporation Atmosphere not built, needs either UG or dune-ALUGrid for the log mesh." << std::endl; return 77; #else typedef TTAG(EvaporationAtmosphereProblem) ProblemTypeTag; diff --git a/test/implicit/mpnc/test_boxmpncthermalnonequil.cc b/test/implicit/mpnc/test_boxmpncthermalnonequil.cc index a577a4ac16..505bf72677 100644 --- a/test/implicit/mpnc/test_boxmpncthermalnonequil.cc +++ b/test/implicit/mpnc/test_boxmpncthermalnonequil.cc @@ -62,7 +62,8 @@ int main(int argc, char** argv) typedef TTAG(CombustionProblemOneComponent) ProblemTypeTag; return Dumux::start<ProblemTypeTag>(argc, argv, usage); #else -#warning CombustionProblemOneComponent skipped, needs Super LU! +#warning CombustionProblemOneComponent skipped, needs SuperLU! + std::cerr << "CombustionProblemOneComponent skipped, needs SuperLU!" << std::endl; return 77; #endif diff --git a/test/multidomain/2cnistokes2p2cni/test_2cnistokes2p2cni.cc b/test/multidomain/2cnistokes2p2cni/test_2cnistokes2p2cni.cc index c6e1c45e12..be4058b07b 100644 --- a/test/multidomain/2cnistokes2p2cni/test_2cnistokes2p2cni.cc +++ b/test/multidomain/2cnistokes2p2cni/test_2cnistokes2p2cni.cc @@ -281,12 +281,10 @@ int main(int argc, char** argv) #else -#warning You need to have dune-multidomain installed to run this test - -int main() +int main(int argc, char** argv) { +#warning You need to have dune-multidomain installed to run this test std::cerr << "You need to have dune-multidomain installed to run this test\n"; return 77; } - #endif diff --git a/test/multidomain/2cnizeroeq2p2cni/test_2cnizeroeq2p2cni.cc b/test/multidomain/2cnizeroeq2p2cni/test_2cnizeroeq2p2cni.cc index e361fbe07d..fff7ec1fdb 100644 --- a/test/multidomain/2cnizeroeq2p2cni/test_2cnizeroeq2p2cni.cc +++ b/test/multidomain/2cnizeroeq2p2cni/test_2cnizeroeq2p2cni.cc @@ -351,13 +351,10 @@ int main(int argc, char** argv) } #else - -#warning You need to have dune-multidomain installed to run this test - int main() { +#warning You need to have dune-multidomain installed to run this test std::cerr << "You need to have dune-multidomain installed to run this test\n"; return 77; } - #endif diff --git a/test/multidomain/2cstokes2p2c/test_2cstokes2p2c.cc b/test/multidomain/2cstokes2p2c/test_2cstokes2p2c.cc index b7da3f07ed..bd8ec6d766 100644 --- a/test/multidomain/2cstokes2p2c/test_2cstokes2p2c.cc +++ b/test/multidomain/2cstokes2p2c/test_2cstokes2p2c.cc @@ -275,13 +275,10 @@ int main(int argc, char** argv) } #else - -#warning You need to have dune-multidomain installed to run this test - -int main() +int main(int argc, char** argv) { +#warning You need to have dune-multidomain installed to run this test std::cerr << "You need to have dune-multidomain installed to run this test\n"; return 77; } - #endif diff --git a/test/multidomain/2czeroeq2p2c/test_2czeroeq2p2c.cc b/test/multidomain/2czeroeq2p2c/test_2czeroeq2p2c.cc index fbd277e3c4..bf443042f5 100644 --- a/test/multidomain/2czeroeq2p2c/test_2czeroeq2p2c.cc +++ b/test/multidomain/2czeroeq2p2c/test_2czeroeq2p2c.cc @@ -339,13 +339,10 @@ int main(int argc, char** argv) } #else - -#warning You need to have dune-multidomain installed to run this test - -int main() +int main(int argc, char** argv) { +#warning You need to have dune-multidomain installed to run this test std::cerr << "You need to have dune-multidomain installed to run this test\n"; return 77; } - #endif -- GitLab