Browse Source

*** empty log message ***

florian 25 years ago
parent
commit
03052cb67e
3 changed files with 29 additions and 0 deletions
  1. 2 0
      tests/test/readme.txt
  2. 7 0
      tests/test/testu1.pp
  3. 20 0
      tests/test/testu2.pp

+ 2 - 0
tests/test/readme.txt

@@ -19,3 +19,5 @@ str/write(real_type) .. strreal.pp     test correct rounding
                         strreal2.pp    test correct writing of 10 till 1e-24
                         strreal2.pp    test correct writing of 10 till 1e-24
 input/output .......... inoutres.pp    tests inoutres values of invalid
 input/output .......... inoutres.pp    tests inoutres values of invalid
                                        operations
                                        operations
+Units ................. testu1.pp      tests init. & finalization and halt
+                        testu2.pp      in finalization

+ 7 - 0
tests/test/testu1.pp

@@ -0,0 +1,7 @@
+uses
+   dotest,testu2;
+
+begin
+   if testvar<>1234567 then
+     do_error(1000);
+end.

+ 20 - 0
tests/test/testu2.pp

@@ -0,0 +1,20 @@
+unit testu2;
+
+  interface
+
+    var
+       testvar : longint;
+
+  implementation
+
+    uses
+       dotest;
+
+initialization
+  testvar:=1234567;
+finalization
+  if testvar<>1234567 then
+    do_error(1001)
+  else
+    halt(0);
+end.