From c2818858e9cd0df8c71a0ec4b811a439aecd7cc5 Mon Sep 17 00:00:00 2001 From: bangerth Date: Tue, 22 May 2012 10:19:14 +0000 Subject: [PATCH] New test. git-svn-id: https://svn.dealii.org/trunk@25536 0785d39b-7218-0410-832d-ea1e28bc413d --- .../deal.II/tria_iterator_with_one_header.cc | 55 +++++++++++++++++++ .../tria_iterator_with_one_header/cmp/generic | 4 ++ 2 files changed, 59 insertions(+) create mode 100644 tests/deal.II/tria_iterator_with_one_header.cc create mode 100644 tests/deal.II/tria_iterator_with_one_header/cmp/generic diff --git a/tests/deal.II/tria_iterator_with_one_header.cc b/tests/deal.II/tria_iterator_with_one_header.cc new file mode 100644 index 0000000000..145c193e91 --- /dev/null +++ b/tests/deal.II/tria_iterator_with_one_header.cc @@ -0,0 +1,55 @@ +//---------------------------- tria_iterator_with_one_header.cc --------------------------- +// $Id$ +// Version: $Name$ +// +// Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2008, 2012 by the deal.II authors +// +// This file is subject to QPL and may not be distributed +// without copyright and license information. Please refer +// to the file deal.II/doc/license.html for the text and +// further information on this license. +// +//---------------------------- tria_iterator_with_one_header.cc --------------------------- + +// It used to be that if you wanted to use +// Triangulation::active_cell_iterator in a context where that type +// was actually used, you also had to #include +// and . +// This was changed in r25531 in such a way that these types are now +// no longer only forward declared. test that this continues to work + +#include "../tests.h" +#include +#include +#include + +#include +#include + +std::ofstream logfile("tria_iterator_with_one_header/output"); + + +template +void test () +{ + Triangulation tria; + GridGenerator::hyper_cube(tria); + deallog << tria.begin_active()->center() << std::endl; +} + + +int main () +{ + deallog << std::setprecision(4); + logfile << std::setprecision(4); + deallog.attach(logfile); + deallog.depth_console(0); + deallog.threshold_double(1.e-10); + + test<1> (); + test<2> (); + test<3> (); + + return 0; +} + diff --git a/tests/deal.II/tria_iterator_with_one_header/cmp/generic b/tests/deal.II/tria_iterator_with_one_header/cmp/generic new file mode 100644 index 0000000000..12ed1622d6 --- /dev/null +++ b/tests/deal.II/tria_iterator_with_one_header/cmp/generic @@ -0,0 +1,4 @@ + +DEAL::0.5000 +DEAL::0.5000 0.5000 +DEAL::0.5000 0.5000 0.5000 -- 2.39.5