Browse Source

* Moved the tregistry2.pp test from packages to tests in order it to be run by daily test runs. tregistry2 has been failing for years and nobody has noticed this.

git-svn-id: trunk@48204 -
(cherry picked from commit a29bfe5505471ef64ac0cb43ea1833d054740a53)

# Conflicts:
#	.gitattributes
#	packages/fcl-registry/tests/testbasics.pp
yury 4 years ago
parent
commit
96710e3168

+ 1 - 13
packages/fcl-registry/tests/testbasics.pp

@@ -21,7 +21,6 @@ type
     procedure TestSimpleWinRegistry;
     procedure TestDoubleWrite;
     procedure bug16395;
-    procedure TestAdv;
     procedure TestStringList;
     Procedure TestInt64;
   end;
@@ -29,11 +28,7 @@ type
 implementation
 
 uses
-  registry
-{$ifdef windows}
-  , tregistry2
-{$endif windows}
-  ;
+  registry;
 
 { TTestBasics }
 
@@ -166,13 +161,6 @@ begin
   DeleteUserXmlFile;
 end;
 
-procedure TTestBasics.TestAdv;
-begin
-{$ifdef windows}
-  DoRegTest2;
-{$endif windows}
-end;
-
 Procedure TTestBasics.TestStringList;
 
 Var

+ 4 - 10
packages/fcl-registry/tests/tregistry2.pp → tests/test/packages/fcl-registry/tregistry2.pp

@@ -4,14 +4,6 @@
 }
 
 {$ifdef FPC} {$mode delphi}  {$endif}
-unit tregistry2;
-
-interface
-
-procedure DoRegTest2;
-
-implementation
-
 uses Windows, SysUtils, Classes, registry;
 
 {$ifdef FPC}
@@ -24,7 +16,8 @@ const
   
 procedure TestFailed(ErrCode: integer);
 begin
-  raise Exception.Create('Test FAILED. Error code: ' + IntToStr(ErrCode));
+  writeln('Test FAILED. Error code: ' + IntToStr(ErrCode));
+  Halt(ErrCode);
 end;
 
 procedure ClearReg(const KeyName: string = '');
@@ -212,5 +205,6 @@ begin
   end;
 end;
 
+begin
+  DoRegTest2;
 end.
-