testrunner.rtlobjpas.pp 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. { %CONFIGFILE=fpcunit-console-defaults.ini testdefaults.ini }
  2. { %SKIPTARGET=embedded,nativent,msdos,win16,macos,palmos }
  3. program testrunner.rtlobjpas;
  4. {$mode objfpc}{$H+}
  5. { Invoke needs a function call manager }
  6. {.$define useffi}
  7. {$if defined(CPUX64) and defined(WINDOWS)}
  8. {$define testinvoke}
  9. {$define testimpl}
  10. {$elseif defined(CPUI386)}
  11. {$define testinvoke}
  12. {$define testimpl}
  13. {$else}
  14. {$ifdef useffi}
  15. {$define testinvoke}
  16. {$define testimpl}
  17. {$endif}
  18. {$endif}
  19. {$IF DEFINED(WINDOWS) or DEFINED(UNIX)}
  20. {$DEFINE HAS_MONITOR}
  21. {$ENDIF}
  22. uses
  23. {$ifdef unix}
  24. cthreads,
  25. cwstring,
  26. {$endif}
  27. {$ifdef useffi}
  28. ffi.manager,
  29. {$endif}
  30. consoletestrunner,
  31. tests.rtti.util,
  32. {$ifdef testinvoke}
  33. tests.rtti.invoke,
  34. {$endif}
  35. {$ifdef testimpl}
  36. tests.rtti.impl,
  37. {$endif}
  38. tests.rtti,
  39. tests.rtti.value,
  40. tests.rtti.types,
  41. utmathvectorbase,
  42. utcmatrix,
  43. utcpoint,
  44. utcvector,
  45. utcquaternion,
  46. {$IFDEF HAS_MONITOR}
  47. utcfpmonitor
  48. {$ENDIF}
  49. ;
  50. var
  51. Application: TTestRunner;
  52. begin
  53. DefaultFormat:=fPlain;
  54. DefaultRunAllTests:=True;
  55. Application := TTestRunner.Create(nil);
  56. Application.Initialize;
  57. Application.Title := 'RTL-ObjPas unit tests';
  58. Application.Run;
  59. Application.Free;
  60. end.