Bläddra i källkod

Shared test header

Kajetan Johannes Hammerle 3 månader sedan
förälder
incheckning
bf8dd240d7
62 ändrade filer med 158 tillägg och 438 borttagningar
  1. 29 29
      CMakeLists.txt
  2. 30 58
      test/Main.cpp
  3. 38 0
      test/Tests.hpp
  4. 2 4
      test/modules/ArrayListTests.cpp
  5. 2 4
      test/modules/ArrayStringTests.cpp
  6. 2 4
      test/modules/ArrayTests.cpp
  7. 2 4
      test/modules/BitArrayTests.cpp
  8. 2 4
      test/modules/BoxTests.cpp
  9. 2 4
      test/modules/BufferTests.cpp
  10. 4 6
      test/modules/BufferedValueTests.cpp
  11. 2 4
      test/modules/ClockTests.cpp
  12. 2 4
      test/modules/ColorTests.cpp
  13. 2 4
      test/modules/ComponentsTests.cpp
  14. 3 5
      test/modules/FileReaderTests.cpp
  15. 2 4
      test/modules/FrustumTests.cpp
  16. 2 4
      test/modules/HashMapTests.cpp
  17. 2 4
      test/modules/LinkedListTests.cpp
  18. 2 4
      test/modules/ListTests.cpp
  19. 2 4
      test/modules/MathTests.cpp
  20. 2 4
      test/modules/MatrixStackTests.cpp
  21. 2 4
      test/modules/MatrixTests.cpp
  22. 2 4
      test/modules/PlaneTests.cpp
  23. 2 4
      test/modules/ProbingHashMapTests.cpp
  24. 2 4
      test/modules/QuaternionTests.cpp
  25. 2 4
      test/modules/RandomTests.cpp
  26. 2 4
      test/modules/RingBufferTests.cpp
  27. 2 4
      test/modules/StackTests.cpp
  28. 2 4
      test/modules/ThreadTests.cpp
  29. 2 4
      test/modules/UniquePointerTests.cpp
  30. 2 4
      test/modules/UtilityTests.cpp
  31. 2 4
      test/modules/VectorTests.cpp
  32. 2 4
      test/modules/ViewTests.cpp
  33. 0 0
      test/modules/resources/test
  34. 0 8
      test/tests/ArrayListTests.hpp
  35. 0 8
      test/tests/ArrayStringTests.hpp
  36. 0 8
      test/tests/ArrayTests.hpp
  37. 0 8
      test/tests/BitArrayTests.hpp
  38. 0 8
      test/tests/BoxTests.hpp
  39. 0 8
      test/tests/BufferTests.hpp
  40. 0 8
      test/tests/BufferedValueTests.hpp
  41. 0 8
      test/tests/ClockTests.hpp
  42. 0 8
      test/tests/ColorTests.hpp
  43. 0 8
      test/tests/ComponentsTests.hpp
  44. 0 8
      test/tests/FileReaderTests.hpp
  45. 0 8
      test/tests/FrustumTests.hpp
  46. 0 8
      test/tests/HashMapTests.hpp
  47. 0 8
      test/tests/LinkedListTests.hpp
  48. 0 8
      test/tests/ListTests.hpp
  49. 0 8
      test/tests/MathTests.hpp
  50. 0 8
      test/tests/MatrixStackTests.hpp
  51. 0 8
      test/tests/MatrixTests.hpp
  52. 0 8
      test/tests/PlaneTests.hpp
  53. 0 8
      test/tests/ProbingHashMapTests.hpp
  54. 0 8
      test/tests/QuaternionTests.hpp
  55. 0 8
      test/tests/RandomTests.hpp
  56. 0 8
      test/tests/RingBufferTests.hpp
  57. 0 8
      test/tests/StackTests.hpp
  58. 0 8
      test/tests/ThreadTests.hpp
  59. 0 8
      test/tests/UniquePointerTests.hpp
  60. 0 8
      test/tests/UtilityTests.hpp
  61. 0 8
      test/tests/VectorTests.hpp
  62. 0 8
      test/tests/ViewTests.hpp

+ 29 - 29
CMakeLists.txt

@@ -27,35 +27,35 @@ set(SRC
 set(SRC_TESTS
     "test/Main.cpp"
     "test/Test.cpp"
-    "test/tests/ArrayTests.cpp"
-    "test/tests/ArrayStringTests.cpp"
-    "test/tests/UtilityTests.cpp"
-    "test/tests/ArrayListTests.cpp"
-    "test/tests/BitArrayTests.cpp"
-    "test/tests/MathTests.cpp"
-    "test/tests/ListTests.cpp"
-    "test/tests/LinkedListTests.cpp"
-    "test/tests/UniquePointerTests.cpp"
-    "test/tests/HashMapTests.cpp"
-    "test/tests/ProbingHashMapTests.cpp"
-    "test/tests/StackTests.cpp"
-    "test/tests/RingBufferTests.cpp"
-    "test/tests/ComponentsTests.cpp"
-    "test/tests/VectorTests.cpp"
-    "test/tests/QuaternionTests.cpp"
-    "test/tests/MatrixTests.cpp"
-    "test/tests/BoxTests.cpp"
-    "test/tests/BufferedValueTests.cpp"
-    "test/tests/PlaneTests.cpp"
-    "test/tests/FrustumTests.cpp"
-    "test/tests/ViewTests.cpp"
-    "test/tests/MatrixStackTests.cpp"
-    "test/tests/ColorTests.cpp"
-    "test/tests/BufferTests.cpp"
-    "test/tests/ClockTests.cpp"
-    "test/tests/RandomTests.cpp"
-    "test/tests/ThreadTests.cpp"
-    "test/tests/FileReaderTests.cpp"
+    "test/modules/ArrayTests.cpp"
+    "test/modules/ArrayStringTests.cpp"
+    "test/modules/UtilityTests.cpp"
+    "test/modules/ArrayListTests.cpp"
+    "test/modules/BitArrayTests.cpp"
+    "test/modules/MathTests.cpp"
+    "test/modules/ListTests.cpp"
+    "test/modules/LinkedListTests.cpp"
+    "test/modules/UniquePointerTests.cpp"
+    "test/modules/HashMapTests.cpp"
+    "test/modules/ProbingHashMapTests.cpp"
+    "test/modules/StackTests.cpp"
+    "test/modules/RingBufferTests.cpp"
+    "test/modules/ComponentsTests.cpp"
+    "test/modules/VectorTests.cpp"
+    "test/modules/QuaternionTests.cpp"
+    "test/modules/MatrixTests.cpp"
+    "test/modules/BoxTests.cpp"
+    "test/modules/BufferedValueTests.cpp"
+    "test/modules/PlaneTests.cpp"
+    "test/modules/FrustumTests.cpp"
+    "test/modules/ViewTests.cpp"
+    "test/modules/MatrixStackTests.cpp"
+    "test/modules/ColorTests.cpp"
+    "test/modules/BufferTests.cpp"
+    "test/modules/ClockTests.cpp"
+    "test/modules/RandomTests.cpp"
+    "test/modules/ThreadTests.cpp"
+    "test/modules/FileReaderTests.cpp"
 )
 
 set(SRC_PERFORMANCE

+ 30 - 58
test/Main.cpp

@@ -1,35 +1,7 @@
 #include "Test.hpp"
+#include "Tests.hpp"
 #include "core/utils/ArrayString.hpp"
 #include "core/utils/Utility.hpp"
-#include "tests/ArrayListTests.hpp"
-#include "tests/ArrayStringTests.hpp"
-#include "tests/ArrayTests.hpp"
-#include "tests/BitArrayTests.hpp"
-#include "tests/BoxTests.hpp"
-#include "tests/BufferTests.hpp"
-#include "tests/BufferedValueTests.hpp"
-#include "tests/ClockTests.hpp"
-#include "tests/ColorTests.hpp"
-#include "tests/ComponentsTests.hpp"
-#include "tests/FileReaderTests.hpp"
-#include "tests/FrustumTests.hpp"
-#include "tests/HashMapTests.hpp"
-#include "tests/LinkedListTests.hpp"
-#include "tests/ListTests.hpp"
-#include "tests/MathTests.hpp"
-#include "tests/MatrixStackTests.hpp"
-#include "tests/MatrixTests.hpp"
-#include "tests/PlaneTests.hpp"
-#include "tests/ProbingHashMapTests.hpp"
-#include "tests/QuaternionTests.hpp"
-#include "tests/RandomTests.hpp"
-#include "tests/RingBufferTests.hpp"
-#include "tests/StackTests.hpp"
-#include "tests/ThreadTests.hpp"
-#include "tests/UniquePointerTests.hpp"
-#include "tests/UtilityTests.hpp"
-#include "tests/VectorTests.hpp"
-#include "tests/ViewTests.hpp"
 
 static void onExit(int code, void* data) {
     unsigned int i = *static_cast<unsigned int*>(data);
@@ -41,35 +13,35 @@ static void onExit(int code, void* data) {
 }
 
 int main() {
-    Core::ArrayListTests::test();
-    Core::ArrayStringTests::test();
-    Core::ArrayTests::test();
-    Core::BitArrayTests::test();
-    Core::BoxTests::test();
-    Core::BufferTests::test();
-    Core::BufferedValueTests::test();
-    Core::ClockTests::test();
-    Core::ColorTests::test();
-    Core::ComponentsTests::test();
-    Core::FileReaderTests::test();
-    Core::FrustumTests::test();
-    Core::HashMapTests::test();
-    Core::LinkedListTests::test();
-    Core::ListTests::test();
-    Core::MathTests::test();
-    Core::MatrixStackTests::test();
-    Core::MatrixTests::test();
-    Core::PlaneTests::test();
-    Core::ProbingHashMapTests::test();
-    Core::QuaternionTests::test();
-    Core::RandomTests::test();
-    Core::RingBufferTests::test();
-    Core::StackTests::test();
-    Core::ThreadTests::test();
-    Core::UniquePointerTests::test();
-    Core::UtilityTests::test();
-    Core::VectorTests::test();
-    Core::ViewTests::test();
+    Core::testArrayList();
+    Core::testArrayString();
+    Core::testArray();
+    Core::testBitArray();
+    Core::testBox();
+    Core::testBuffer();
+    Core::testBufferedValue();
+    Core::testClock();
+    Core::testColor();
+    Core::testComponents();
+    Core::testFileReader();
+    Core::testFrustum();
+    Core::testHashMap();
+    Core::testLinkedList();
+    Core::testList();
+    Core::testMath();
+    Core::testMatrixStack();
+    Core::testMatrix();
+    Core::testPlane();
+    Core::testProbingHashMap();
+    Core::testQuaternion();
+    Core::testRandom();
+    Core::testRingBuffer();
+    Core::testStack();
+    Core::testThread();
+    Core::testUniquePointer();
+    Core::testUtility();
+    Core::testVector();
+    Core::testView();
 
     unsigned int data = 123456789;
     Core::setExitHandler(onExit, &data);

+ 38 - 0
test/Tests.hpp

@@ -0,0 +1,38 @@
+#ifndef CORE_TESTS_HPP
+#define CORE_TESTS_HPP
+
+#include "Test.hpp"
+
+namespace Core {
+    void testArrayList();
+    void testArrayString();
+    void testArray();
+    void testBitArray();
+    void testBox();
+    void testBuffer();
+    void testBufferedValue();
+    void testClock();
+    void testColor();
+    void testComponents();
+    void testFileReader();
+    void testFrustum();
+    void testHashMap();
+    void testLinkedList();
+    void testList();
+    void testMath();
+    void testMatrixStack();
+    void testMatrix();
+    void testPlane();
+    void testProbingHashMap();
+    void testQuaternion();
+    void testRandom();
+    void testRingBuffer();
+    void testStack();
+    void testThread();
+    void testUniquePointer();
+    void testUtility();
+    void testVector();
+    void testView();
+}
+
+#endif

+ 2 - 4
test/tests/ArrayListTests.cpp → test/modules/ArrayListTests.cpp

@@ -1,6 +1,4 @@
-#include "ArrayListTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/data/ArrayList.hpp"
 
 using IntList = Core::ArrayList<int, 20>;
@@ -143,7 +141,7 @@ static void testRemove() {
     CORE_TEST_EQUAL(0, list.getLength());
 }
 
-void Core::ArrayListTests::test() {
+void Core::testArrayList() {
     testAdd();
     testMultipleAdd();
     testAddReplace();

+ 2 - 4
test/tests/ArrayStringTests.cpp → test/modules/ArrayStringTests.cpp

@@ -1,6 +1,4 @@
-#include "ArrayStringTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/data/HashMap.hpp"
 #include "core/utils/ArrayString.hpp"
 
@@ -892,7 +890,7 @@ static void testConversion() {
     CORE_TEST_STRING(b, sb2);
 }
 
-void Core::ArrayStringTests::test() {
+void Core::testArrayString() {
     testEquality8();
     testUnicodeEquality8();
     testInequality8();

+ 2 - 4
test/tests/ArrayTests.cpp → test/modules/ArrayTests.cpp

@@ -1,6 +1,4 @@
-#include "ArrayTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/data/Array.hpp"
 
 static void testToString1() {
@@ -17,7 +15,7 @@ static void testToString2() {
     CORE_TEST_STRING("[1]", a);
 }
 
-void Core::ArrayTests::test() {
+void Core::testArray() {
     testToString1();
     testToString2();
 }

+ 2 - 4
test/tests/BitArrayTests.cpp → test/modules/BitArrayTests.cpp

@@ -1,6 +1,4 @@
-#include "BitArrayTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/data/BitArray.hpp"
 
 static void testSetRead() {
@@ -107,7 +105,7 @@ static void testToString3() {
     CORE_TEST_STRING("[]", bits);
 }
 
-void Core::BitArrayTests::test() {
+void Core::testBitArray() {
     testSetRead();
     testOutOfBoundsSetRead();
     testBigSetRead();

+ 2 - 4
test/tests/BoxTests.cpp → test/modules/BoxTests.cpp

@@ -1,6 +1,4 @@
-#include "BoxTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/math/Box.hpp"
 
 static void testInit() {
@@ -53,7 +51,7 @@ static void testGrow() {
                      box.grow(Core::Vector3(-0.1f, -4.0f, -1.0f)));
 }
 
-void Core::BoxTests::test() {
+void Core::testBox() {
     testInit();
     testOffset();
     testCollidesWith();

+ 2 - 4
test/tests/BufferTests.cpp → test/modules/BufferTests.cpp

@@ -1,6 +1,4 @@
-#include "BufferTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/utils/Buffer.hpp"
 
 static constexpr int SIZE_TYPES =
@@ -62,7 +60,7 @@ static void testMove() {
     CORE_TEST_EQUAL(SIZE_TYPES * 10, buffer2.getLength());
 }
 
-void Core::BufferTests::test() {
+void Core::testBuffer() {
     testAdd();
     testCopy();
     testMoveConstruct();

+ 4 - 6
test/tests/BufferedValueTests.cpp → test/modules/BufferedValueTests.cpp

@@ -1,6 +1,4 @@
-#include "BufferedValueTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/math/BufferedValue.hpp"
 #include "core/math/Vector.hpp"
 
@@ -44,7 +42,7 @@ static void testCalculate() {
     CORE_TEST_FLOAT(12.0f, b + 2.0f, eps);
 }
 
-static void testVector() {
+static void testVector2() {
     Core::Vector2 base(5.0f, 6.0f);
     Core::BufferedValue<Core::Vector2> b = base;
 
@@ -81,10 +79,10 @@ static void testVector() {
     CORE_TEST_VECTOR(Core::Vector2(4.0f, 1.0f), b.get(1.0f));
 }
 
-void Core::BufferedValueTests::test() {
+void Core::testBufferedValue() {
     testInit();
     testInterpolate();
     testUpdate();
     testCalculate();
-    testVector();
+    testVector2();
 }

+ 2 - 4
test/tests/ClockTests.cpp → test/modules/ClockTests.cpp

@@ -1,6 +1,4 @@
-#include "ClockTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/utils/Clock.hpp"
 
 static void testUpdate() {
@@ -38,7 +36,7 @@ static void testWait(Core::Clock::Nanos wait) {
     CORE_TEST_TRUE(n2 >= wait && n2 <= wait * 11 / 10);
 }
 
-void Core::ClockTests::test() {
+void Core::testClock() {
     testUpdate();
     testUpdatesPerSecond();
     testWait(50'000'000);

+ 2 - 4
test/tests/ColorTests.cpp → test/modules/ColorTests.cpp

@@ -1,6 +1,4 @@
-#include "ColorTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/utils/Color.hpp"
 
 const float eps = 0.0001f;
@@ -49,7 +47,7 @@ static void testColor4Empty() {
     CORE_TEST_EQUAL(0, c[3]);
 }
 
-void Core::ColorTests::test() {
+void Core::testColor() {
     testColor1();
     testColor2();
     testColor3();

+ 2 - 4
test/tests/ComponentsTests.cpp → test/modules/ComponentsTests.cpp

@@ -1,6 +1,4 @@
-#include "ComponentsTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/data/Components.hpp"
 
 using IntComponent = Core::Components<int>;
@@ -151,7 +149,7 @@ static void testRemove() {
     CORE_TEST_NULL(c.search(10));
 }
 
-void Core::ComponentsTests::test() {
+void Core::testComponents() {
     testAddForEach();
     testAddComponentForEach();
     testRemove();

+ 3 - 5
test/tests/FileReaderTests.cpp → test/modules/FileReaderTests.cpp

@@ -1,9 +1,7 @@
-#include "FileReaderTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/io/FileReader.hpp"
 
-static constexpr const char* TEST_FILE = "../test/tests/resources/test";
+static constexpr const char* TEST_FILE = "../test/modules/resources/test";
 
 static void testReadChar() {
     Core::FileReader r;
@@ -63,7 +61,7 @@ static void testMoveAssignment() {
     CORE_TEST_EQUAL('a', c);
 }
 
-void Core::FileReaderTests::test() {
+void Core::testFileReader() {
     testReadChar();
     testReadChars();
     testReadCharsOverflow();

+ 2 - 4
test/tests/FrustumTests.cpp → test/modules/FrustumTests.cpp

@@ -1,6 +1,4 @@
-#include "FrustumTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/math/Frustum.hpp"
 
 using V3 = Core::Vector3;
@@ -48,7 +46,7 @@ static void testSphereIsInside() {
     CORE_TEST_TRUE(f.isInside(V3(-50.0f, 0.0f, 5.0f), 50.0f));
 }
 
-void Core::FrustumTests::test() {
+void Core::testFrustum() {
     testToString();
     testPointIsInside();
     testSphereIsInside();

+ 2 - 4
test/tests/HashMapTests.cpp → test/modules/HashMapTests.cpp

@@ -1,6 +1,4 @@
-#include "HashMapTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/data/HashMap.hpp"
 
 using IntMap = Core::HashMap<int, int>;
@@ -312,7 +310,7 @@ static void testTypes() {
     testType<unsigned long long>();
 }
 
-void Core::HashMapTests::test() {
+void Core::testHashMap() {
     testAdd();
     testMultipleAdd();
     testSearch();

+ 2 - 4
test/tests/LinkedListTests.cpp → test/modules/LinkedListTests.cpp

@@ -1,6 +1,4 @@
-#include "LinkedListTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/data/LinkedList.hpp"
 
 struct LinkedListTester final {
@@ -273,7 +271,7 @@ static void testRemoveLast() {
     CORE_TEST_EQUAL(0, list.getLength());
 }
 
-void Core::LinkedListTests::test() {
+void Core::testLinkedList() {
     testWithoutCopyOrMove();
     testAdd();
     testMultipleAdd();

+ 2 - 4
test/tests/ListTests.cpp → test/modules/ListTests.cpp

@@ -1,6 +1,4 @@
-#include "ListTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/data/List.hpp"
 
 using IntList = Core::List<int>;
@@ -183,7 +181,7 @@ static void testDefaultResize() {
     }
 }
 
-void Core::ListTests::test() {
+void Core::testList() {
     testAdd();
     testMultipleAdd();
     testAddReplace();

+ 2 - 4
test/tests/MathTests.cpp → test/modules/MathTests.cpp

@@ -1,6 +1,4 @@
-#include "MathTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/math/Math.hpp"
 
 constexpr float eps = 0.0001f;
@@ -93,7 +91,7 @@ static void testDegreeToRadian() {
     CORE_TEST_FLOAT(CMath::PI * 2.0f, CMath::degreeToRadian(360.0f), eps);
 }
 
-void Core::MathTests::test() {
+void Core::testMath() {
     testInterpolate();
     testIsPowerOf2();
     testRoundUpLog2();

+ 2 - 4
test/tests/MatrixStackTests.cpp → test/modules/MatrixStackTests.cpp

@@ -1,6 +1,4 @@
-#include "MatrixStackTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/math/MatrixStack.hpp"
 
 using Matrices = Core::MatrixStack<5>;
@@ -99,7 +97,7 @@ static void testToString3() {
                      stack);
 }
 
-void Core::MatrixStackTests::test() {
+void Core::testMatrixStack() {
     testInit();
     testPop();
     testPush();

+ 2 - 4
test/tests/MatrixTests.cpp → test/modules/MatrixTests.cpp

@@ -1,6 +1,4 @@
-#include "MatrixTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/math/Matrix.hpp"
 
 using V3 = Core::Vector3;
@@ -159,7 +157,7 @@ static void testQuaternionMatrix() {
     }
 }
 
-void Core::MatrixTests::test() {
+void Core::testMatrix() {
     testInit();
     testScale();
     testUniformScale();

+ 2 - 4
test/tests/PlaneTests.cpp → test/modules/PlaneTests.cpp

@@ -1,6 +1,4 @@
-#include "PlaneTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/math/Plane.hpp"
 
 const float eps = 0.0001f;
@@ -32,7 +30,7 @@ static void testSignedDistance() {
                     eps);
 }
 
-void Core::PlaneTests::test() {
+void Core::testPlane() {
     testToString1();
     testToString2();
     testSignedDistance();

+ 2 - 4
test/tests/ProbingHashMapTests.cpp → test/modules/ProbingHashMapTests.cpp

@@ -1,8 +1,6 @@
-#include "ProbingHashMapTests.hpp"
-
 #include <stdio.h>
 
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/data/ProbingHashMap.hpp"
 
 using IntMap = Core::ProbingHashMap<int, int>;
@@ -309,7 +307,7 @@ static void testTypes() {
     testType<unsigned long long>();
 }
 
-void Core::ProbingHashMapTests::test() {
+void Core::testProbingHashMap() {
     testAdd();
     testMultipleAdd();
     testSearch();

+ 2 - 4
test/tests/QuaternionTests.cpp → test/modules/QuaternionTests.cpp

@@ -1,6 +1,4 @@
-#include "QuaternionTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/math/Quaternion.hpp"
 
 using V3 = Core::Vector3;
@@ -61,7 +59,7 @@ static void testMulVector() {
     CORE_TEST_VECTOR(V3(0.0f, 0.0f, 1.0f), q3 * v3);
 }
 
-void Core::QuaternionTests::test() {
+void Core::testQuaternion() {
     testInit();
     testAxisAndDegreesInit();
     testLerp();

+ 2 - 4
test/tests/RandomTests.cpp → test/modules/RandomTests.cpp

@@ -1,6 +1,4 @@
-#include "RandomTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/data/Array.hpp"
 #include "core/utils/Random.hpp"
 
@@ -68,7 +66,7 @@ static void testFloatDistribution() {
     }
 }
 
-void Core::RandomTests::test() {
+void Core::testRandom() {
     testAverage();
     testCoin();
     testDistribution();

+ 2 - 4
test/tests/RingBufferTests.cpp → test/modules/RingBufferTests.cpp

@@ -1,6 +1,4 @@
-#include "RingBufferTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/data/RingBuffer.hpp"
 
 struct Tester final {
@@ -258,7 +256,7 @@ static void testOverall() {
     CORE_TEST_EQUAL(0, Tester::sum);
 }
 
-void Core::RingBufferTests::test() {
+void Core::testRingBuffer() {
     testReadAndWrite();
     testOverflow();
     testRefill();

+ 2 - 4
test/tests/StackTests.cpp → test/modules/StackTests.cpp

@@ -1,6 +1,4 @@
-#include "StackTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/data/Stack.hpp"
 
 template<typename T>
@@ -70,7 +68,7 @@ static void testType(int amount) {
     testPop<T>();
 }
 
-void Core::StackTests::test() {
+void Core::testStack() {
     testType<Core::ListStack<int>>(100000);
     testType<Core::ArrayStack<int, 100>>(100);
 }

+ 2 - 4
test/tests/ThreadTests.cpp → test/modules/ThreadTests.cpp

@@ -1,6 +1,4 @@
-#include "ThreadTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/thread/Thread.hpp"
 
 static int runDone = 0;
@@ -43,7 +41,7 @@ static void testJoinWithoutStart() {
     CORE_TEST_EQUAL(Core::Error::THREAD_ERROR, t.join(nullptr));
 }
 
-void Core::ThreadTests::test() {
+void Core::testThread() {
     testStart();
     testLambda();
     testJoinWithoutStart();

+ 2 - 4
test/tests/UniquePointerTests.cpp → test/modules/UniquePointerTests.cpp

@@ -1,6 +1,4 @@
-#include "UniquePointerTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/utils/UniquePointer.hpp"
 
 struct B final {
@@ -36,7 +34,7 @@ static void testMoveDestroys() {
     CORE_TEST_EQUAL(0, B::instances);
 }
 
-void Core::UniquePointerTests::test() {
+void Core::testUniquePointer() {
     testDestroy();
     testMoveDestroys();
 }

+ 2 - 4
test/tests/UtilityTests.cpp → test/modules/UtilityTests.cpp

@@ -1,6 +1,4 @@
-#include "UtilityTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/utils/Utility.hpp"
 
 static void testPopCount() {
@@ -20,7 +18,7 @@ static void testIf() {
     CORE_TEST_TRUE((Core::IsSame<Core::If<false, int, double>, double>));
 }
 
-void Core::UtilityTests::test() {
+void Core::testUtility() {
     testPopCount();
     testIf();
 }

+ 2 - 4
test/tests/VectorTests.cpp → test/modules/VectorTests.cpp

@@ -1,6 +1,4 @@
-#include "VectorTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/math/Vector.hpp"
 
 const float eps = 0.0001f;
@@ -192,7 +190,7 @@ static void testToString() {
     CORE_TEST_EQUAL(s2, s);
 }
 
-void Core::VectorTests::test() {
+void Core::testVector() {
     testInitAndRead();
     testSetAngles();
     testCross();

+ 2 - 4
test/tests/ViewTests.cpp → test/modules/ViewTests.cpp

@@ -1,6 +1,4 @@
-#include "ViewTests.hpp"
-
-#include "../Test.hpp"
+#include "../Tests.hpp"
 #include "core/math/View.hpp"
 
 using V3 = Core::Vector3;
@@ -27,7 +25,7 @@ static void testFromQuaternion() {
     CORE_TEST_VECTOR(V3(-1.0f, 0.0f, 0.0f), v.getBack());
 }
 
-void Core::ViewTests::test() {
+void Core::testView() {
     testFromAngles();
     testFromQuaternion();
 }

+ 0 - 0
test/tests/resources/test → test/modules/resources/test


+ 0 - 8
test/tests/ArrayListTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_ARRAY_LIST_TESTS_HPP
-#define CORE_ARRAY_LIST_TESTS_HPP
-
-namespace Core::ArrayListTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/ArrayStringTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_ARRAY_STRING_TESTS_HPP
-#define CORE_ARRAY_STRING_TESTS_HPP
-
-namespace Core::ArrayStringTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/ArrayTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_ARRAY_TESTS_HPP
-#define CORE_ARRAY_TESTS_HPP
-
-namespace Core::ArrayTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/BitArrayTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_BIT_ARRAY_TESTS_HPP
-#define CORE_BIT_ARRAY_TESTS_HPP
-
-namespace Core::BitArrayTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/BoxTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_BOX_TESTS_HPP
-#define CORE_BOX_TESTS_HPP
-
-namespace Core::BoxTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/BufferTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_BUFFER_TESTS_HPP
-#define CORE_BUFFER_TESTS_HPP
-
-namespace Core::BufferTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/BufferedValueTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_BUFFERED_VALUE_TESTS_HPP
-#define CORE_BUFFERED_VALUE_TESTS_HPP
-
-namespace Core::BufferedValueTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/ClockTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_CLOCK_TESTS_HPP
-#define CORE_CLOCK_TESTS_HPP
-
-namespace Core::ClockTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/ColorTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_COLOR_TESTS_HPP
-#define CORE_COLOR_TESTS_HPP
-
-namespace Core::ColorTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/ComponentsTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_COMPONENTS_TESTS_HPP
-#define CORE_COMPONENTS_TESTS_HPP
-
-namespace Core::ComponentsTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/FileReaderTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_FILE_READER_TESTS_HPP
-#define CORE_FILE_READER_TESTS_HPP
-
-namespace Core::FileReaderTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/FrustumTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_FRUSTUM_TESTS_HPP
-#define CORE_FRUSTUM_TESTS_HPP
-
-namespace Core::FrustumTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/HashMapTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_HPPASHMAP_TESTS_HPP
-#define CORE_HPPASHMAP_TESTS_HPP
-
-namespace Core::HashMapTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/LinkedListTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_LINKED_LIST_TESTS_HPP
-#define CORE_LINKED_LIST_TESTS_HPP
-
-namespace Core::LinkedListTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/ListTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_LIST_TESTS_HPP
-#define CORE_LIST_TESTS_HPP
-
-namespace Core::ListTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/MathTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_MATH_TESTS_HPP
-#define CORE_MATH_TESTS_HPP
-
-namespace Core::MathTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/MatrixStackTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_MATRIX_STACK_TESTS_HPP
-#define CORE_MATRIX_STACK_TESTS_HPP
-
-namespace Core::MatrixStackTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/MatrixTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_MATRIX_TESTS_HPP
-#define CORE_MATRIX_TESTS_HPP
-
-namespace Core::MatrixTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/PlaneTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_PLANE_TESTS_HPP
-#define CORE_PLANE_TESTS_HPP
-
-namespace Core::PlaneTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/ProbingHashMapTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_PROBING_HPPASHMAP_TESTS_HPP
-#define CORE_PROBING_HPPASHMAP_TESTS_HPP
-
-namespace Core::ProbingHashMapTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/QuaternionTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_QUATERNION_TESTS_HPP
-#define CORE_QUATERNION_TESTS_HPP
-
-namespace Core::QuaternionTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/RandomTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_RANDOM_TESTS_HPP
-#define CORE_RANDOM_TESTS_HPP
-
-namespace Core::RandomTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/RingBufferTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_RINGBUFFER_TESTS_HPP
-#define CORE_RINGBUFFER_TESTS_HPP
-
-namespace Core::RingBufferTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/StackTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_STACKTESTS_HPP
-#define CORE_STACKTESTS_HPP
-
-namespace Core::StackTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/ThreadTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_THREAD_TESTS_HPP
-#define CORE_THREAD_TESTS_HPP
-
-namespace Core::ThreadTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/UniquePointerTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_UNIQUE_POINTER_TESTS_HPP
-#define CORE_UNIQUE_POINTER_TESTS_HPP
-
-namespace Core::UniquePointerTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/UtilityTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_UTILITY_TESTS_HPP
-#define CORE_UTILITY_TESTS_HPP
-
-namespace Core::UtilityTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/VectorTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_VECTOR_TESTS_HPP
-#define CORE_VECTOR_TESTS_HPP
-
-namespace Core::VectorTests {
-    void test();
-}
-
-#endif

+ 0 - 8
test/tests/ViewTests.hpp

@@ -1,8 +0,0 @@
-#ifndef CORE_VIEW_TESTS_HPP
-#define CORE_VIEW_TESTS_HPP
-
-namespace Core::ViewTests {
-    void test();
-}
-
-#endif