Main.cpp 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. #include "test/Test.h"
  2. #include "tests/ArrayListTests.h"
  3. #include "tests/ArrayStringTests.h"
  4. #include "tests/ArrayTests.h"
  5. #include "tests/BitArrayTests.h"
  6. #include "tests/BoxTests.h"
  7. #include "tests/BufferTests.h"
  8. #include "tests/BufferedValueTests.h"
  9. #include "tests/ClockTests.h"
  10. #include "tests/ColorTests.h"
  11. #include "tests/ComponentsTests.h"
  12. #include "tests/FileReaderTests.h"
  13. #include "tests/FrustumTests.h"
  14. #include "tests/HashMapTests.h"
  15. #include "tests/LinkedListTests.h"
  16. #include "tests/ListTests.h"
  17. #include "tests/MathTests.h"
  18. #include "tests/MatrixStackTests.h"
  19. #include "tests/MatrixTests.h"
  20. #include "tests/PlaneTests.h"
  21. #include "tests/ProbingHashMapTests.h"
  22. #include "tests/QuaternionTests.h"
  23. #include "tests/RandomTests.h"
  24. #include "tests/RingBufferTests.h"
  25. #include "tests/StackTests.h"
  26. #include "tests/ThreadTests.h"
  27. #include "tests/UniquePointerTests.h"
  28. #include "tests/UtilityTests.h"
  29. #include "tests/VectorTests.h"
  30. #include "tests/ViewTests.h"
  31. #include "utils/ArrayString.h"
  32. #include "utils/Utility.h"
  33. static void onExit(int code, void* data) {
  34. unsigned int i = *static_cast<unsigned int*>(data);
  35. Core::String32<1024> s;
  36. CORE_TEST_ERROR(s.append("Hello from exit #: #"));
  37. CORE_TEST_ERROR(s.format(code, i));
  38. CORE_TEST_ERROR(s.printLine());
  39. Core::Test::finalize();
  40. }
  41. int main() {
  42. Core::ArrayListTests::test();
  43. Core::ArrayStringTests::test();
  44. Core::ArrayTests::test();
  45. Core::BitArrayTests::test();
  46. Core::BoxTests::test();
  47. Core::BufferTests::test();
  48. Core::BufferedValueTests::test();
  49. Core::ClockTests::test();
  50. Core::ColorTests::test();
  51. Core::ComponentsTests::test();
  52. Core::FileReaderTests::test();
  53. Core::FrustumTests::test();
  54. Core::HashMapTests::test();
  55. Core::LinkedListTests::test();
  56. Core::ListTests::test();
  57. Core::MathTests::test();
  58. Core::MatrixStackTests::test();
  59. Core::MatrixTests::test();
  60. Core::PlaneTests::test();
  61. Core::ProbingHashMapTests::test();
  62. Core::QuaternionTests::test();
  63. Core::RandomTests::test();
  64. Core::RingBufferTests::test();
  65. Core::StackTests::test();
  66. Core::ThreadTests::test();
  67. Core::UniquePointerTests::test();
  68. Core::UtilityTests::test();
  69. Core::VectorTests::test();
  70. Core::ViewTests::test();
  71. unsigned int data = 123456789;
  72. Core::setExitHandler(onExit, &data);
  73. CORE_EXIT(1);
  74. return 0;
  75. }