]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
first round of regression test tests
authorkanschat <kanschat@0785d39b-7218-0410-832d-ea1e28bc413d>
Thu, 14 Sep 2006 15:55:49 +0000 (15:55 +0000)
committerkanschat <kanschat@0785d39b-7218-0410-832d-ea1e28bc413d>
Thu, 14 Sep 2006 15:55:49 +0000 (15:55 +0000)
git-svn-id: https://svn.dealii.org/trunk@13901 0785d39b-7218-0410-832d-ea1e28bc413d

14 files changed:
tests/test/Makefile [new file with mode: 0644]
tests/test/README [new file with mode: 0644]
tests/test/no_compile_01.cc [new file with mode: 0644]
tests/test/no_diff_01.cc [new file with mode: 0644]
tests/test/no_diff_01/cmp/generic [new file with mode: 0644]
tests/test/no_diff_02/cmp/generic [new file with mode: 0644]
tests/test/no_diff_03.cc [new file with mode: 0644]
tests/test/no_diff_03/cmp/generic [new file with mode: 0644]
tests/test/no_diff_04/cmp/generic [new file with mode: 0644]
tests/test/no_link_01.cc [new file with mode: 0644]
tests/test/no_run_01.cc [new file with mode: 0644]
tests/test/no_run_03.cc [new file with mode: 0644]
tests/test/ok_01.cc [new file with mode: 0644]
tests/test/ok_01/cmp/generic [new file with mode: 0644]

diff --git a/tests/test/Makefile b/tests/test/Makefile
new file mode 100644 (file)
index 0000000..70d7170
--- /dev/null
@@ -0,0 +1,43 @@
+############################################################
+# $Id: Makefile 13841 2006-09-06 21:04:19Z kanschat $
+# Copyright (C) 2006 by the deal.II authors
+############################################################
+
+############################################################
+# Test if test suite reports the expected results
+#
+# This directory contains tests failing at different stages.
+# When running all tests, this should be reflected in the results.
+#
+############################################################
+
+include ../Makefile.paths
+include $D/common/Make.global_options
+debug-mode = on
+
+default: run-tests 
+
+############################################################
+
+tests_x = no_compile_* no_link_* no_run_* no_diff_* ok_*
+
+# from above list of regular expressions, generate the real set of
+# tests
+expand = $(shell echo $(addsuffix .cc,$(1)) \
+           | $(PERL) -pi -e 's/\.cc//g;')
+tests = $(call expand,$(tests_x))
+
+############################################################
+# phony header file to force compilation whenever
+# make is invoked
+############################################################
+
+phony.h:
+       touch phony.h
+
+
+include ../Makefile.rules
+include Makefile.depend
+include Makefile.tests
+
+.PHONY: default phony.h
diff --git a/tests/test/README b/tests/test/README
new file mode 100644 (file)
index 0000000..bf33e41
--- /dev/null
@@ -0,0 +1 @@
+This directory tests the testsuite, not the deal.II library!
\ No newline at end of file
diff --git a/tests/test/no_compile_01.cc b/tests/test/no_compile_01.cc
new file mode 100644 (file)
index 0000000..513d461
--- /dev/null
@@ -0,0 +1,19 @@
+//----------------------------------------------------------------------
+//    $Id: reference.cc 13395 2006-07-19 12:45:54Z kanschat $
+//    Version: $Name$ 
+//
+//    Copyright (C) 2006 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.
+//
+//----------------------------------------------------------------------
+
+// A test program that won't compile
+
+int main()
+{
+  not_declared();
+}
diff --git a/tests/test/no_diff_01.cc b/tests/test/no_diff_01.cc
new file mode 100644 (file)
index 0000000..ad5012b
--- /dev/null
@@ -0,0 +1,22 @@
+//----------------------------------------------------------------------
+//    $Id: reference.cc 13395 2006-07-19 12:45:54Z kanschat $
+//    Version: $Name$ 
+//
+//    Copyright (C) 2006 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.
+//
+//----------------------------------------------------------------------
+
+// A test program that won't run, but produces results
+
+
+#include <cstdlib>
+#include <fstream>
+
+int main()
+{
+}
diff --git a/tests/test/no_diff_01/cmp/generic b/tests/test/no_diff_01/cmp/generic
new file mode 100644 (file)
index 0000000..e2da009
--- /dev/null
@@ -0,0 +1 @@
+other results
diff --git a/tests/test/no_diff_02/cmp/generic b/tests/test/no_diff_02/cmp/generic
new file mode 100644 (file)
index 0000000..e2da009
--- /dev/null
@@ -0,0 +1 @@
+other results
diff --git a/tests/test/no_diff_03.cc b/tests/test/no_diff_03.cc
new file mode 100644 (file)
index 0000000..a7e88ac
--- /dev/null
@@ -0,0 +1,24 @@
+//----------------------------------------------------------------------
+//    $Id: reference.cc 13395 2006-07-19 12:45:54Z kanschat $
+//    Version: $Name$ 
+//
+//    Copyright (C) 2006 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.
+//
+//----------------------------------------------------------------------
+
+// A test program that produces wrong results
+
+
+#include <cstdlib>
+#include <fstream>
+
+int main()
+{
+  std::ofstream out("no_diff_03/output");
+  out << "My output" << std::endl;
+}
diff --git a/tests/test/no_diff_03/cmp/generic b/tests/test/no_diff_03/cmp/generic
new file mode 100644 (file)
index 0000000..e2da009
--- /dev/null
@@ -0,0 +1 @@
+other results
diff --git a/tests/test/no_diff_04/cmp/generic b/tests/test/no_diff_04/cmp/generic
new file mode 100644 (file)
index 0000000..e2da009
--- /dev/null
@@ -0,0 +1 @@
+other results
diff --git a/tests/test/no_link_01.cc b/tests/test/no_link_01.cc
new file mode 100644 (file)
index 0000000..41e64fb
--- /dev/null
@@ -0,0 +1,21 @@
+//----------------------------------------------------------------------
+//    $Id: reference.cc 13395 2006-07-19 12:45:54Z kanschat $
+//    Version: $Name$ 
+//
+//    Copyright (C) 2006 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.
+//
+//----------------------------------------------------------------------
+
+// A test program that won't link
+
+void not_implemented();
+
+int main()
+{
+  not_implemented();
+}
diff --git a/tests/test/no_run_01.cc b/tests/test/no_run_01.cc
new file mode 100644 (file)
index 0000000..a2f89b1
--- /dev/null
@@ -0,0 +1,22 @@
+//----------------------------------------------------------------------
+//    $Id: reference.cc 13395 2006-07-19 12:45:54Z kanschat $
+//    Version: $Name$ 
+//
+//    Copyright (C) 2006 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.
+//
+//----------------------------------------------------------------------
+
+// A test program that won't run and does not produce results
+
+
+#include <cstdlib>
+
+int main()
+{
+  exit(1);
+}
diff --git a/tests/test/no_run_03.cc b/tests/test/no_run_03.cc
new file mode 100644 (file)
index 0000000..f5f80d4
--- /dev/null
@@ -0,0 +1,26 @@
+//----------------------------------------------------------------------
+//    $Id: reference.cc 13395 2006-07-19 12:45:54Z kanschat $
+//    Version: $Name$ 
+//
+//    Copyright (C) 2006 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.
+//
+//----------------------------------------------------------------------
+
+// A test program that won't run, but produces results
+
+
+#include <cstdlib>
+#include <fstream>
+
+int main()
+{
+  std::ofstream out("no_run_03/output");
+  out << "My output" << std::endl;
+  
+  exit(1);
+}
diff --git a/tests/test/ok_01.cc b/tests/test/ok_01.cc
new file mode 100644 (file)
index 0000000..b387bdf
--- /dev/null
@@ -0,0 +1,24 @@
+//----------------------------------------------------------------------
+//    $Id: reference.cc 13395 2006-07-19 12:45:54Z kanschat $
+//    Version: $Name$ 
+//
+//    Copyright (C) 2006 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.
+//
+//----------------------------------------------------------------------
+
+// A test program that produces correct results
+
+
+#include <cstdlib>
+#include <fstream>
+
+int main()
+{
+  std::ofstream out("ok_01/output");
+  out << "My output" << std::endl;
+}
diff --git a/tests/test/ok_01/cmp/generic b/tests/test/ok_01/cmp/generic
new file mode 100644 (file)
index 0000000..09f0171
--- /dev/null
@@ -0,0 +1 @@
+My output

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.