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

tests/test/Makefile
tests/test/README
tests/test/no_compile_02.cc [new file with mode: 0644]
tests/test/no_diff_01.cc
tests/test/no_link_02.cc [new file with mode: 0644]
tests/test/no_run_02.cc [new file with mode: 0644]
tests/test/no_run_03/cmp/generic [new file with mode: 0644]
tests/test/no_run_04.cc [new file with mode: 0644]
tests/test/no_run_04/cmp/generic [new file with mode: 0644]

index 70d7170ccfd045034be22abeecae6076151802ce..a0d3e9b740979c5aff25985cfaa43399984ed57e 100644 (file)
@@ -35,6 +35,10 @@ tests = $(call expand,$(tests_x))
 phony.h:
        touch phony.h
 
+### Make sure even numbers are are always recompiled
+
+no_*_?[02468]/obj.g.o:     phony.h
+
 
 include ../Makefile.rules
 include Makefile.depend
index bf33e41ee579c6889d766ff05459e79934bcc67a..61da174e97080d014f797bc070f5c28e5ec3c5ff 100644 (file)
@@ -1 +1,15 @@
-This directory tests the testsuite, not the deal.II library!
\ No newline at end of file
+This directory tests the testsuite, not the deal.II library!
+
+Things that should be checked for when changing the implementation of
+the test suite:
+
+1. After make clean, first and second run should produce same results
+2. Tests with even number should produce same results as previous odd number
+3. Tests should produce results as indicated by their name
+
+
+
+Remarks on the implementation
+
+The file phony.h is used to make sure compilation is started in EVERY
+run of make for targets with even numbers.
diff --git a/tests/test/no_compile_02.cc b/tests/test/no_compile_02.cc
new file mode 100644 (file)
index 0000000..3f0db50
--- /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 compile
+
+#include "phony.h"
+
+int main()
+{
+  not_declared();
+}
index ad5012b6a92647110228e0c54db5d72d0481be99..2179f84a7147e75f8aacd87d9425c5a5260cbbeb 100644 (file)
@@ -11,7 +11,7 @@
 //
 //----------------------------------------------------------------------
 
-// A test program that won't run, but produces results
+// A test program runs, but won't produce results
 
 
 #include <cstdlib>
diff --git a/tests/test/no_link_02.cc b/tests/test/no_link_02.cc
new file mode 100644 (file)
index 0000000..c8d0074
--- /dev/null
@@ -0,0 +1,23 @@
+//----------------------------------------------------------------------
+//    $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
+
+#include "phony.h"
+
+void not_implemented();
+
+int main()
+{
+  not_implemented();
+}
diff --git a/tests/test/no_run_02.cc b/tests/test/no_run_02.cc
new file mode 100644 (file)
index 0000000..f2a1721
--- /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 won't run and does not produce results
+
+
+#include <cstdlib>
+
+#include "phony.h"
+
+int main()
+{
+  exit(1);
+}
diff --git a/tests/test/no_run_03/cmp/generic b/tests/test/no_run_03/cmp/generic
new file mode 100644 (file)
index 0000000..09f0171
--- /dev/null
@@ -0,0 +1 @@
+My output
diff --git a/tests/test/no_run_04.cc b/tests/test/no_run_04.cc
new file mode 100644 (file)
index 0000000..fadf723
--- /dev/null
@@ -0,0 +1,28 @@
+//----------------------------------------------------------------------
+//    $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>
+
+#include "phony.h"
+
+int main()
+{
+  std::ofstream out("no_run_04/output");
+  out << "My output" << std::endl;
+  
+  exit(1);
+}
diff --git a/tests/test/no_run_04/cmp/generic b/tests/test/no_run_04/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.