From: Timo Heister Date: Fri, 27 Sep 2013 12:34:40 +0000 (+0000) Subject: add simplified test that crashes in release mode X-Git-Tag: v8.1.0~570^2~178 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=354f25009afad7b49f36785f37b6e082cbeb64ef;p=dealii.git add simplified test that crashes in release mode git-svn-id: https://svn.dealii.org/branches/branch_port_the_testsuite@30974 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/tests/mpi/constraint_matrix_crash_01.cc b/tests/mpi/constraint_matrix_crash_01.cc new file mode 100644 index 0000000000..74f4a764ef --- /dev/null +++ b/tests/mpi/constraint_matrix_crash_01.cc @@ -0,0 +1,54 @@ +// --------------------------------------------------------------------- +// $Id: constraint_matrix_set_zero_02.cc 30694 2013-09-13 17:22:08Z maier $ +// +// Copyright (C) 2013 by the deal.II authors +// +// This file is part of the deal.II library. +// +// The deal.II library is free software; you can use it, redistribute +// it, and/or modify it under the terms of the GNU Lesser General +// Public License as published by the Free Software Foundation; either +// version 2.1 of the License, or (at your option) any later version. +// The full text of the license can be found in the file LICENSE at +// the top level of the deal.II distribution. +// +// --------------------------------------------------------------------- + + + +// ConstraintMatrix::add_line crashes in release mode + +#include "../tests.h" +#include +#include +#include +#include +#include + +#include + + +void test () +{ + unsigned int myid = Utilities::MPI::this_mpi_process (MPI_COMM_WORLD); + unsigned int numproc = Utilities::MPI::n_mpi_processes (MPI_COMM_WORLD); + + IndexSet local_active_together(3); + local_active_together.add_range(0,1); + local_active_together.add_range(1,3); + + ConstraintMatrix cm(local_active_together); + cm.add_line(1); + cm.close(); + deallog << "OK" << std::endl; +} + + +int main(int argc, char *argv[]) +{ + Utilities::MPI::MPI_InitFinalize mpi_initialization(argc, argv, 1); + MPILogInitAll log; + + test(); + return 0; +} diff --git a/tests/mpi/constraint_matrix_crash_01.mpirun=1.output b/tests/mpi/constraint_matrix_crash_01.mpirun=1.output new file mode 100644 index 0000000000..be8d055f86 --- /dev/null +++ b/tests/mpi/constraint_matrix_crash_01.mpirun=1.output @@ -0,0 +1,2 @@ + +DEAL:0::OK