Browse Source

* write additional info for the tests, might help to identify spurious failures

florian 8 months ago
parent
commit
c48d8e9708
2 changed files with 25 additions and 0 deletions
  1. 16 0
      tests/test/tstack.pp
  2. 9 0
      tests/webtbs/tw40598.pp

+ 16 - 0
tests/test/tstack.pp

@@ -1,3 +1,8 @@
+{$ifdef linux}
+uses
+  baseunix;
+{$endif linux}
+
 {$ifdef CPUAVR}
 { avr does not support an exitproc }
 begin
@@ -60,7 +65,18 @@ begin
   exitproc:=saveexit;
 end;
 
+{$ifdef linux}
+var
+  limits : TRLimit;
+{$endif linux}
+
 begin
+{$ifdef linux}
+  FpGetRLimit(RLIMIT_STACK, @limits);
+  writeln('Cur: ',limits.rlim_cur);
+  writeln('Max: ',limits.rlim_max);
+  writeln('StackLength: ',StackLength);
+{$endif linux}
   saveexit:=exitproc;
   exitproc:=@stack_check_exit;
   x:=inf_rec(5000);

+ 9 - 0
tests/webtbs/tw40598.pp

@@ -17,8 +17,17 @@ end;
 
 var
   Form1 : TForm1;
+{$ifdef linux}
+  limits : TRLimit;
+{$endif linux}
 
 begin
+{$ifdef linux}
+  FpGetRLimit(RLIMIT_STACK, @limits);
+  writeln('Cur: ',limits.rlim_cur);
+  writeln('Max: ',limits.rlim_max);
+  writeln('StackLength: ',StackLength);
+{$endif linux}
   Form1:=TForm1.Create;
   Form1.Button1Click(nil);
 end.