aboutsummaryrefslogtreecommitdiff
path: root/src/test
diff options
context:
space:
mode:
authorLoek Le Blansch <loek@pipeframe.xyz>2024-11-21 10:00:35 +0100
committerLoek Le Blansch <loek@pipeframe.xyz>2024-11-21 10:00:35 +0100
commit70b1bf50de703330436f2ae9cb103fe33cbb567e (patch)
tree6e5c9bc256ae8392f94d2d863ecd345f6246927f /src/test
parentaa00be5fae68e4ccb7b592f1193d86f09105723a (diff)
`make format`
Diffstat (limited to 'src/test')
-rw-r--r--src/test/SceneManagerTest.cpp4
-rw-r--r--src/test/ScriptTest.cpp11
2 files changed, 6 insertions, 9 deletions
diff --git a/src/test/SceneManagerTest.cpp b/src/test/SceneManagerTest.cpp
index dab2ce9..1efcfb2 100644
--- a/src/test/SceneManagerTest.cpp
+++ b/src/test/SceneManagerTest.cpp
@@ -21,7 +21,7 @@ public:
GameObject object3 = mgr.new_object("scene_1", "tag_scene_1", Vector2{2, 0}, 0, 1);
}
- string get_name() const { return "scene1";}
+ string get_name() const { return "scene1"; }
};
class ConcreteScene2 : public Scene {
@@ -36,7 +36,7 @@ public:
GameObject object4 = mgr.new_object("scene_2", "tag_scene_2", Vector2{0, 3}, 0, 1);
}
- string get_name() const { return "scene2";}
+ string get_name() const { return "scene2"; }
};
class SceneManagerTest : public ::testing::Test {
diff --git a/src/test/ScriptTest.cpp b/src/test/ScriptTest.cpp
index 875c422..c35c3e2 100644
--- a/src/test/ScriptTest.cpp
+++ b/src/test/ScriptTest.cpp
@@ -6,18 +6,18 @@
#include <crepe/ComponentManager.h>
#include <crepe/api/BehaviorScript.h>
+#include <crepe/api/Event.h>
+#include <crepe/api/EventManager.h>
#include <crepe/api/GameObject.h>
#include <crepe/api/Script.h>
#include <crepe/api/Vector2.h>
-#include <crepe/api/Event.h>
-#include <crepe/api/EventManager.h>
#include <crepe/system/ScriptSystem.h>
using namespace std;
using namespace crepe;
using namespace testing;
-class MyEvent : public Event { };
+class MyEvent : public Event {};
class ScriptTest : public Test {
public:
@@ -39,9 +39,7 @@ public:
// init should never be called more than once
EXPECT_LE(this->init_count, 1);
}
- void update() {
- this->update_count++;
- }
+ void update() { this->update_count++; }
public:
unsigned init_count = 0;
@@ -125,4 +123,3 @@ TEST_F(ScriptTest, ListScripts) {
}
ASSERT_EQ(1, script_count);
}
-