tcprecompile.pas 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610
  1. {
  2. This file is part of the Free Component Library (FCL)
  3. Copyright (c) 2018 by Michael Van Canneyt
  4. Unit tests for Pascal-to-Javascript converter class.
  5. See the file COPYING.FPC, included in this distribution,
  6. for details about the copyright.
  7. This program is distributed in the hope that it will be useful,
  8. but WITHOUT ANY WARRANTY; without even the implied warranty of
  9. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  10. **********************************************************************
  11. Examples:
  12. ./testpas2js --suite=TTestCLI_Precompile
  13. ./testpas2js --suite=TTestModule.TestEmptyUnit
  14. }
  15. unit TCPrecompile;
  16. {$mode objfpc}{$H+}
  17. interface
  18. uses
  19. Classes, SysUtils,
  20. fpcunit, testregistry, Pas2jsFileUtils, Pas2JsFiler, Pas2jsCompiler,
  21. TCUnitSearch, TCModules;
  22. type
  23. { TCustomTestCLI_Precompile }
  24. TCustomTestCLI_Precompile = class(TCustomTestCLI)
  25. private
  26. FPCUFormat: TPas2JSPrecompileFormat;
  27. FUnitOutputDir: string;
  28. protected
  29. procedure SetUp; override;
  30. procedure CheckPrecompile(MainFile, UnitPaths: string;
  31. SharedParams: TStringList = nil;
  32. FirstRunParams: TStringList = nil;
  33. SecondRunParams: TStringList = nil; ExpExitCode: integer = 0);
  34. function GetJSFilename(ModuleName: string): string; virtual;
  35. public
  36. constructor Create; override;
  37. property PCUFormat: TPas2JSPrecompileFormat read FPCUFormat write FPCUFormat;
  38. property UnitOutputDir: string read FUnitOutputDir write FUnitOutputDir;
  39. end;
  40. { TTestCLI_Precompile }
  41. TTestCLI_Precompile = class(TCustomTestCLI_Precompile)
  42. published
  43. procedure TestPCU_EmptyUnit;
  44. procedure TestPCU_UTF8BOM;
  45. procedure TestPCU_ParamNS;
  46. procedure TestPCU_Overloads;
  47. procedure TestPCU_Overloads_MDelphi_ModeObjFPC;
  48. procedure TestPCU_UnitCycle;
  49. procedure TestPCU_Class_Forward;
  50. procedure TestPCU_Class_Constructor;
  51. procedure TestPCU_Class_ClassConstructor;
  52. procedure TestPCU_ClassInterface;
  53. procedure TestPCU_Namespace;
  54. procedure TestPCU_CheckVersionMain;
  55. procedure TestPCU_CheckVersionMain2;
  56. procedure TestPCU_CheckVersionSystem;
  57. end;
  58. function LinesToList(const Lines: array of string): TStringList;
  59. implementation
  60. function LinesToList(const Lines: array of string): TStringList;
  61. var
  62. i: Integer;
  63. begin
  64. Result:=TStringList.Create;
  65. for i:=Low(Lines) to High(Lines) do Result.Add(Lines[i]);
  66. end;
  67. { TCustomTestCLI_Precompile }
  68. procedure TCustomTestCLI_Precompile.SetUp;
  69. begin
  70. inherited SetUp;
  71. UnitOutputDir:='units';
  72. end;
  73. procedure TCustomTestCLI_Precompile.CheckPrecompile(MainFile,
  74. UnitPaths: string; SharedParams: TStringList; FirstRunParams: TStringList;
  75. SecondRunParams: TStringList; ExpExitCode: integer);
  76. var
  77. JSFilename, OrigSrc, NewSrc, s: String;
  78. JSFile: TCLIFile;
  79. begin
  80. try
  81. AddDir(UnitOutputDir);
  82. // compile, create .pcu files
  83. {$IFDEF VerbosePCUFiler}
  84. writeln('TTestCLI_Precompile.CheckPrecompile create pcu files=========================');
  85. {$ENDIF}
  86. Params.Clear;
  87. Params.Add('-Jminclude');
  88. Params.Add('-Jc');
  89. if SharedParams<>nil then
  90. Params.AddStrings(SharedParams);
  91. if FirstRunParams<>nil then
  92. Params.AddStrings(FirstRunParams);
  93. Compile([MainFile,'-Fu'+UnitPaths,'-JU'+PCUFormat.Ext,'-FU'+UnitOutputDir]);
  94. AssertFileExists(UnitOutputDir+'/system.'+PCUFormat.Ext);
  95. JSFilename:=GetJSFilename(MainFile);
  96. AssertFileExists(JSFilename);
  97. JSFile:=FindFile(JSFilename);
  98. OrigSrc:=JSFile.Source;
  99. // compile, using .pcu files
  100. //for i:=0 to FileCount-1 do
  101. // writeln('TCustomTestCLI_Precompile.CheckPrecompile ',i,' ',Files[i].Filename);
  102. {$IFDEF VerbosePCUFiler}
  103. writeln('TTestCLI_Precompile.CheckPrecompile compile using pcu files==================');
  104. {$ENDIF}
  105. JSFile.Source:='';
  106. Compiler.Reset;
  107. Params.Clear;
  108. Params.Add('-Jminclude');
  109. Params.Add('-Jc');
  110. if SharedParams<>nil then
  111. Params.AddStrings(SharedParams);
  112. if SecondRunParams<>nil then
  113. Params.AddStrings(SecondRunParams);
  114. Compile([MainFile,'-FU'+UnitOutputDir],ExpExitCode);
  115. if ExpExitCode=0 then
  116. begin
  117. NewSrc:=JSFile.Source;
  118. if not CheckSrcDiff(OrigSrc,NewSrc,s) then
  119. begin
  120. WriteSources;
  121. writeln('TCustomTestCLI_Precompile.CheckPrecompile OrigSrc==================');
  122. writeln(OrigSrc);
  123. writeln('TCustomTestCLI_Precompile.CheckPrecompile NewSrc==================');
  124. writeln(NewSrc);
  125. Fail('test1.js: '+s);
  126. end;
  127. end;
  128. finally
  129. SharedParams.Free;
  130. FirstRunParams.Free;
  131. SecondRunParams.Free;
  132. end;
  133. end;
  134. function TCustomTestCLI_Precompile.GetJSFilename(ModuleName: string): string;
  135. begin
  136. Result:=UnitOutputDir+PathDelim+ExtractFilenameOnly(ModuleName)+'.js';
  137. end;
  138. constructor TCustomTestCLI_Precompile.Create;
  139. begin
  140. inherited Create;
  141. FPCUFormat:=PrecompileFormats[0];
  142. end;
  143. { TTestCLI_Precompile }
  144. procedure TTestCLI_Precompile.TestPCU_EmptyUnit;
  145. begin
  146. AddUnit('src/system.pp',[''],['']);
  147. AddFile('test1.pas',[
  148. 'begin',
  149. 'end.']);
  150. CheckPrecompile('test1.pas','src');
  151. end;
  152. procedure TTestCLI_Precompile.TestPCU_UTF8BOM;
  153. var
  154. aFile: TCLIFile;
  155. begin
  156. aFile:=AddUnit('src/system.pp',
  157. ['var',
  158. ' s: string = ''aaaäö'';',
  159. ' s2: string = ''😊'';', // 1F60A
  160. ''],
  161. ['']);
  162. aFile.Source:=UTF8BOM+aFile.Source;
  163. aFile:=AddFile('test1.pas',[
  164. 'begin',
  165. ' s:=''ö😊'';',
  166. 'end.']);
  167. aFile.Source:=UTF8BOM+aFile.Source;
  168. CheckPrecompile('test1.pas','src');
  169. end;
  170. procedure TTestCLI_Precompile.TestPCU_ParamNS;
  171. begin
  172. AddUnit('src/system.pp',[''],['']);
  173. AddUnit('src/foo.unit1.pp',['var i: longint;'],['']);
  174. AddFile('test1.pas',[
  175. 'uses unit1;',
  176. 'begin',
  177. ' i:=3;',
  178. 'end.']);
  179. CheckPrecompile('test1.pas','src',LinesToList(['-FNfoo']));
  180. end;
  181. procedure TTestCLI_Precompile.TestPCU_Overloads;
  182. begin
  183. AddUnit('src/system.pp',['type integer = longint;'],['']);
  184. AddUnit('src/unit1.pp',
  185. ['var i: integer;',
  186. 'procedure DoIt(j: integer); overload;',
  187. 'procedure DoIt(b: boolean);'],
  188. ['procedure DoIt(j: integer);',
  189. 'begin',
  190. ' i:=j;',
  191. 'end;',
  192. 'procedure DoIt(b: boolean);',
  193. 'begin',
  194. ' i:=3;',
  195. 'end;']);
  196. AddUnit('src/unit2.pp',
  197. ['uses unit1;',
  198. 'procedure DoIt(s: string); overload;'],
  199. ['procedure DoIt(s: string);',
  200. 'begin',
  201. ' unit1.i:=length(s);',
  202. 'end;']);
  203. AddFile('test1.pas',[
  204. 'uses unit1, unit2;',
  205. 'procedure DoIt(d: double); overload;',
  206. 'begin',
  207. ' unit1.i:=4;',
  208. 'end;',
  209. 'begin',
  210. ' DoIt(3);',
  211. ' DoIt(''abc'');',
  212. ' DoIt(true);',
  213. ' DoIt(3.3);',
  214. 'end.']);
  215. CheckPrecompile('test1.pas','src');
  216. end;
  217. procedure TTestCLI_Precompile.TestPCU_Overloads_MDelphi_ModeObjFPC;
  218. var
  219. SharedParams: TStringList;
  220. begin
  221. AddUnit('src/system.pp',[
  222. 'type',
  223. ' integer = longint;',
  224. ' TDateTime = type double;'],
  225. ['']);
  226. AddFile('src/unit1.pp',
  227. LinesToStr([
  228. 'unit unit1;',
  229. '{$mode objfpc}',
  230. 'interface',
  231. 'function DoIt(i: integer): TDateTime;', // no overload needed in ObjFPC
  232. 'function DoIt(i, j: integer): TDateTime;',
  233. 'implementation',
  234. 'function DoIt(i: integer): TDateTime;',
  235. 'begin',
  236. ' Result:=i;',
  237. 'end;',
  238. 'function DoIt(i, j: integer): TDateTime;',
  239. 'begin',
  240. ' Result:=i+j;',
  241. 'end;',
  242. 'end.']));
  243. AddFile('test1.pas',[
  244. 'uses unit1;',
  245. 'var d: TDateTime;',
  246. 'begin',
  247. ' d:=DoIt(3);',
  248. ' d:=DoIt(4,5);',
  249. 'end.']);
  250. SharedParams:=TStringList.Create;
  251. SharedParams.Add('-MDelphi');
  252. CheckPrecompile('test1.pas','src',SharedParams);
  253. end;
  254. procedure TTestCLI_Precompile.TestPCU_UnitCycle;
  255. begin
  256. AddUnit('src/system.pp',['type integer = longint;'],['']);
  257. AddUnit('src/unit1.pp',
  258. ['var i: integer;',
  259. 'procedure Do1(j: integer);'],
  260. ['uses unit2;',
  261. 'procedure Do1(j: integer);',
  262. 'begin',
  263. ' Do2(j);',
  264. 'end;']);
  265. AddUnit('src/unit2.pp',
  266. ['uses unit1;',
  267. 'procedure Do2(j: integer);'],
  268. ['procedure Do2(j: integer);',
  269. 'begin',
  270. ' unit1.i:=j;',
  271. 'end;']);
  272. AddFile('test1.pas',[
  273. 'uses unit1;',
  274. 'begin',
  275. ' Do1(3);',
  276. 'end.']);
  277. CheckPrecompile('test1.pas','src');
  278. end;
  279. procedure TTestCLI_Precompile.TestPCU_Class_Forward;
  280. begin
  281. AddUnit('src/system.pp',[
  282. 'type integer = longint;',
  283. 'procedure Writeln; varargs;'],
  284. ['procedure Writeln; begin end;']);
  285. AddUnit('src/unit1.pp',
  286. ['type',
  287. ' TClass = class of TObject;',
  288. ' TBirdClass = class of TBird;',
  289. ' TObject = class',
  290. ' FBirdClass: TBirdClass;',
  291. ' constructor Create;',
  292. ' constructor Create(Id: integer);',
  293. ' property BirdClass: TBirdClass read FBirdClass;',
  294. ' end;',
  295. ' TBird = class',
  296. ' constructor Create(d: double); overload;',
  297. ' end;',
  298. ''],
  299. ['constructor TObject.Create; begin end;',
  300. 'constructor TObject.Create(Id: integer); begin end;',
  301. 'constructor TBird.Create(d: double); begin end;']);
  302. AddFile('test1.pas',[
  303. 'uses unit1;',
  304. 'var',
  305. ' b: TBird;',
  306. ' c: TClass;',
  307. 'begin',
  308. ' c:=TObject;',
  309. ' c:=TBird;',
  310. ' c:=b.BirdClass;',
  311. ' b:=TBird.Create;',
  312. ' b:=TBird.Create(1);',
  313. ' b:=TBird.Create(3.3);',
  314. 'end.']);
  315. CheckPrecompile('test1.pas','src');
  316. end;
  317. procedure TTestCLI_Precompile.TestPCU_Class_Constructor;
  318. begin
  319. AddUnit('src/system.pp',[
  320. 'type integer = longint;',
  321. 'procedure Writeln; varargs;'],
  322. ['procedure Writeln; begin end;']);
  323. AddUnit('src/unit1.pp',[
  324. 'type',
  325. ' TObject = class',
  326. ' constructor Create;',
  327. ' end;',
  328. ' TBird = class',
  329. ' constructor Create; reintroduce;',
  330. ' end;',
  331. ' TCow = class',
  332. ' constructor Create; reintroduce;',
  333. ' end;',
  334. ''],[
  335. 'constructor TObject.Create; begin end;',
  336. 'constructor TBird.Create; begin end;',
  337. 'constructor TCow.Create; begin end;',
  338. '']);
  339. AddUnit('src/unit2.pp',[
  340. 'uses unit1;',
  341. 'procedure DoIt;',
  342. ''],[
  343. 'procedure DoIt;',
  344. 'begin',
  345. ' TBird.Create;',
  346. ' TCow.Create;',
  347. 'end;',
  348. '']);
  349. AddFile('test1.pas',[
  350. 'uses unit2;',
  351. 'begin',
  352. ' DoIt;',
  353. 'end.']);
  354. CheckPrecompile('test1.pas','src');
  355. end;
  356. procedure TTestCLI_Precompile.TestPCU_Class_ClassConstructor;
  357. begin
  358. AddUnit('src/system.pp',[
  359. 'type integer = longint;',
  360. 'procedure Writeln; varargs;'],
  361. ['procedure Writeln; begin end;']);
  362. AddUnit('src/unit1.pp',[
  363. 'type',
  364. ' TObject = class',
  365. ' constructor Create;',
  366. ' end;',
  367. ' TBird = class',
  368. ' class constructor InitBird;',
  369. ' end;',
  370. ''],[
  371. 'constructor TObject.Create; begin end;',
  372. 'class constructor TBird.InitBird;',
  373. 'begin',
  374. ' exit;',
  375. 'end;',
  376. '']);
  377. AddUnit('src/unit2.pp',[
  378. 'uses unit1;',
  379. 'procedure DoIt;',
  380. ''],[
  381. 'procedure DoIt;',
  382. 'begin',
  383. ' TBird.Create;',
  384. 'end;',
  385. '']);
  386. AddFile('test1.pas',[
  387. 'uses unit2;',
  388. 'begin',
  389. ' DoIt;',
  390. 'end.']);
  391. CheckPrecompile('test1.pas','src');
  392. end;
  393. procedure TTestCLI_Precompile.TestPCU_ClassInterface;
  394. begin
  395. AddUnit('src/system.pp',[
  396. '{$interfaces corba}',
  397. 'type',
  398. ' integer = longint;',
  399. ' IUnknown = interface',
  400. ' end;',
  401. 'procedure Writeln; varargs;'],
  402. ['procedure Writeln; begin end;']);
  403. AddUnit('src/unit1.pp',[
  404. 'type',
  405. ' IIntf = interface',
  406. ' function GetItems(Index: longint): longint;',
  407. ' procedure SetItems(Index: longint; Value: longint);',
  408. ' property Items[Index: longint]: longint read GetItems write SetItems; default;',
  409. ' end;',
  410. ''],[
  411. '']);
  412. AddUnit('src/unit2.pp',[
  413. 'uses unit1;',
  414. 'type',
  415. ' IAlias = IIntf;',
  416. ' TObject = class end;',
  417. ' TBird = class(IIntf)',
  418. ' strict private',
  419. ' function IIntf.GetItems = FetchItems;',
  420. ' function FetchItems(Index: longint): longint; virtual; abstract;',
  421. ' procedure SetItems(Index: longint; Value: longint); virtual; abstract;',
  422. ' end;',
  423. ''],[
  424. '']);
  425. AddUnit('src/unit3.pp',[
  426. 'uses unit2;',
  427. 'type',
  428. ' TEagle = class(TBird)',
  429. ' function FetchItems(Index: longint): longint; override;',
  430. ' procedure SetItems(Index: longint; Value: longint); override;',
  431. ' end;',
  432. ' TFlying = class(IAlias)',
  433. ' strict private',
  434. ' FEagle: TEagle;',
  435. ' property Eagle: TEagle read FEagle implements IAlias;',
  436. ' public',
  437. ' constructor Create;',
  438. ' end;',
  439. ''],[
  440. 'function TEagle.FetchItems(Index: longint): longint; begin end;',
  441. 'procedure TEagle.SetItems(Index: longint; Value: longint); begin end;',
  442. 'constructor TFlying.Create;',
  443. 'begin',
  444. ' FEagle:=nil;',
  445. 'end;',
  446. '']);
  447. AddFile('test1.pas',[
  448. 'uses unit2, unit3;',
  449. 'type IAlias2 = IAlias;',
  450. 'var',
  451. ' f: TFlying;',
  452. ' i: IAlias2;',
  453. 'begin',
  454. ' f:=TFlying.Create;',
  455. ' i:=f;',
  456. ' i[2]:=i[3];',
  457. 'end.']);
  458. CheckPrecompile('test1.pas','src');
  459. end;
  460. procedure TTestCLI_Precompile.TestPCU_Namespace;
  461. begin
  462. AddUnit('src/system.pp',[
  463. 'type integer = longint;',
  464. 'procedure Writeln; varargs;'],
  465. ['procedure Writeln; begin end;']);
  466. AddUnit('src/Web.Unit1.pp',[
  467. 'var i: integer;',
  468. ''],[
  469. '']);
  470. AddUnit('src/Unit2.pp',[
  471. 'uses WEB.uNit1;',
  472. 'procedure DoIt;',
  473. ''],[
  474. 'procedure DoIt;',
  475. 'begin',
  476. ' writeln(i);',
  477. 'end;',
  478. '']);
  479. AddFile('test1.pas',[
  480. 'uses unIT2;',
  481. 'begin',
  482. ' DoIt;',
  483. 'end.']);
  484. CheckPrecompile('test1.pas','src');
  485. AssertFileExists(UnitOutputDir+'/Unit2.'+PCUFormat.Ext);
  486. AssertFileExists(UnitOutputDir+'/Web.Unit1.'+PCUFormat.Ext);
  487. end;
  488. procedure TTestCLI_Precompile.TestPCU_CheckVersionMain;
  489. var
  490. aFile: TCLIFile;
  491. s, JSFilename, ExpectedSrc: string;
  492. begin
  493. AddUnit('src/system.pp',[
  494. 'type integer = longint;'],
  495. ['']);
  496. AddFile('test1.pas',[
  497. 'begin',
  498. 'end.']);
  499. CheckPrecompile('test1.pas','src',LinesToList(['-JoCheckVersion=Main','-Jm-','-Jc-']));
  500. JSFilename:=GetJSFilename('test1.js');
  501. aFile:=FindFile(JSFilename);
  502. AssertNotNull('File not found '+JSFilename,aFile);
  503. ExpectedSrc:=LinesToStr([
  504. UTF8BOM+'rtl.module("program",["system"],function () {',
  505. ' "use strict";',
  506. ' var $mod = this;',
  507. ' $mod.$main = function () {',
  508. ' rtl.checkVersion('+IntToStr((VersionMajor*100+VersionMinor)*100+VersionRelease)+');',
  509. ' };',
  510. '});']);
  511. if not CheckSrcDiff(ExpectedSrc,aFile.Source,s) then
  512. Fail('TTestCLI_Precompile.TestPCU_CheckVersionMain src diff: '+s);
  513. end;
  514. procedure TTestCLI_Precompile.TestPCU_CheckVersionMain2;
  515. var
  516. aFile: TCLIFile;
  517. s, JSFilename, ExpectedSrc: string;
  518. begin
  519. AddUnit('src/system.pp',[
  520. 'type integer = longint;',
  521. 'procedure Writeln; varargs;'],
  522. ['procedure Writeln; begin end;']);
  523. AddFile('test1.pas',[
  524. 'begin',
  525. ' Writeln;',
  526. 'end.']);
  527. CheckPrecompile('test1.pas','src',LinesToList(['-JoCheckVersion=Main','-Jm-','-Jc-']));
  528. JSFilename:=GetJSFilename('test1.js');
  529. aFile:=FindFile(JSFilename);
  530. AssertNotNull('File not found '+JSFilename,aFile);
  531. ExpectedSrc:=LinesToStr([
  532. UTF8BOM+'rtl.module("program",["system"],function () {',
  533. ' "use strict";',
  534. ' var $mod = this;',
  535. ' $mod.$main = function () {',
  536. ' rtl.checkVersion('+IntToStr((VersionMajor*100+VersionMinor)*100+VersionRelease)+');',
  537. ' pas.system.Writeln();',
  538. ' };',
  539. '});']);
  540. if not CheckSrcDiff(ExpectedSrc,aFile.Source,s) then
  541. Fail('TTestCLI_Precompile.TestPCU_CheckVersionMain src diff: '+s);
  542. end;
  543. procedure TTestCLI_Precompile.TestPCU_CheckVersionSystem;
  544. var
  545. aFile: TCLIFile;
  546. s, JSFilename, ExpectedSrc, VerStr: string;
  547. begin
  548. AddUnit('src/system.pp',[
  549. 'type integer = longint;'],
  550. ['']);
  551. AddFile('test1.pas',[
  552. 'begin',
  553. 'end.']);
  554. CheckPrecompile('test1.pas','src',LinesToList(['-JoCheckVersion=system','-Jm-','-Jc-']));
  555. JSFilename:=GetJSFilename('system.js');
  556. aFile:=FindFile(JSFilename);
  557. AssertNotNull('File not found '+JSFilename,aFile);
  558. writeln('TTestCLI_Precompile.TestPCU_CheckVersionMain ',aFile.Source);
  559. VerStr:=IntToStr((VersionMajor*100+VersionMinor)*100+VersionRelease);
  560. ExpectedSrc:=LinesToStr([
  561. UTF8BOM+'rtl.module("system",[],function () {',
  562. ' "use strict";',
  563. ' rtl.checkVersion('+VerStr+');',
  564. ' var $mod = this;',
  565. '});']);
  566. if not CheckSrcDiff(ExpectedSrc,aFile.Source,s) then
  567. Fail('TTestCLI_Precompile.TestPCU_CheckVersionMain src diff: '+s);
  568. end;
  569. Initialization
  570. RegisterTests([TTestCLI_Precompile]);
  571. RegisterPCUFormat;
  572. end.