From bab2d9e0a54d3e7694c71cd0bddec5ac1951543f Mon Sep 17 00:00:00 2001 From: maier Date: Sun, 20 Oct 2013 15:27:49 +0000 Subject: [PATCH] Make the output of petsc_solver_(02|11) more robust git-svn-id: https://svn.dealii.org/branches/branch_port_the_testsuite@31338 0785d39b-7218-0410-832d-ea1e28bc413d --- tests/petsc/solver_02.cc | 8 ++++---- tests/petsc/solver_02.output | 4 ++-- tests/petsc/solver_11.cc | 4 ++-- tests/petsc/solver_11.output | 2 +- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/tests/petsc/solver_02.cc b/tests/petsc/solver_02.cc index 2f8f6a04e0..0a49a88c5c 100644 --- a/tests/petsc/solver_02.cc +++ b/tests/petsc/solver_02.cc @@ -45,11 +45,11 @@ check_solve( SOLVER &solver, const MATRIX &A, { solver.solve(A,u,f,P); } - catch (std::exception &e) + catch (dealii::SolverControl::NoConvergence &e) { - deallog << e.what() << std::endl; - // just like for Richardson: we end up - // here normally for this solver + // just like for Richardson: expect to + // get here, don't abort the program + deallog << "Catched exception dealii::SolverControl::NoConvergence" << std::endl; } deallog << "Solver stopped after " << solver.control().last_step() diff --git a/tests/petsc/solver_02.output b/tests/petsc/solver_02.output index 47abf08e11..451d0391cc 100644 --- a/tests/petsc/solver_02.output +++ b/tests/petsc/solver_02.output @@ -2,6 +2,6 @@ DEAL::Size 32 Unknowns 961 DEAL::Solver type: N6dealii13PETScWrappers15SolverChebychevE DEAL::Starting value 7.551 -DEAL::Failure step 100 value 2.942 -DEAL::Iterative method reported convergence failure in step 100 with residual 2.94179 +DEAL::Failure step 100 value 2.937 +DEAL::Catched exception dealii::SolverControl::NoConvergence DEAL::Solver stopped after 100 iterations diff --git a/tests/petsc/solver_11.cc b/tests/petsc/solver_11.cc index dc40e6a01f..a7e585eb33 100644 --- a/tests/petsc/solver_11.cc +++ b/tests/petsc/solver_11.cc @@ -45,11 +45,11 @@ check_solve( SOLVER &solver, const MATRIX &A, { solver.solve(A,u,f,P); } - catch (std::exception &e) + catch (dealii::SolverControl::NoConvergence &e) { - deallog << e.what() << std::endl; // just like for Richardson: expect to // get here, don't abort the program + deallog << "Catched exception dealii::SolverControl::NoConvergence" << std::endl; } deallog << "Solver stopped after " << solver.control().last_step() diff --git a/tests/petsc/solver_11.output b/tests/petsc/solver_11.output index d253157365..b5aa43b077 100644 --- a/tests/petsc/solver_11.output +++ b/tests/petsc/solver_11.output @@ -3,5 +3,5 @@ DEAL::Size 32 Unknowns 961 DEAL::Solver type: N6dealii13PETScWrappers10SolverLSQRE DEAL::Starting value 31.00 DEAL::Failure step 100 value 24.02 -DEAL::Iterative method reported convergence failure in step 100 with residual 24.0171 +DEAL::Catched exception dealii::SolverControl::NoConvergence DEAL::Solver stopped after 100 iterations -- 2.39.5