aboutsummaryrefslogtreecommitdiff
path: root/src/test/EventTest.cpp
diff options
context:
space:
mode:
authorWBoerenkamps <wrj.boerenkamps@student.avans.nl>2024-12-07 15:32:47 +0100
committerWBoerenkamps <wrj.boerenkamps@student.avans.nl>2024-12-07 15:32:47 +0100
commit24c9a9ab277897a7191d4e99213c2ab9f5d4ecd8 (patch)
tree0e5f9dc8be0592431b52149db51337ccf3bc2e7f /src/test/EventTest.cpp
parent0f2451f4d48c78426c2663501e6cdd6871f1e94a (diff)
make format
Diffstat (limited to 'src/test/EventTest.cpp')
-rw-r--r--src/test/EventTest.cpp13
1 files changed, 5 insertions, 8 deletions
diff --git a/src/test/EventTest.cpp b/src/test/EventTest.cpp
index 8479998..82272b5 100644
--- a/src/test/EventTest.cpp
+++ b/src/test/EventTest.cpp
@@ -1,8 +1,8 @@
-#include <gmock/gmock.h>
-#include <gtest/gtest.h>
#include <crepe/api/Event.h>
#include <crepe/manager/EventManager.h>
#include <crepe/manager/Mediator.h>
+#include <gmock/gmock.h>
+#include <gtest/gtest.h>
using namespace std;
using namespace std::chrono_literals;
using namespace crepe;
@@ -53,13 +53,11 @@ TEST_F(EventManagerTest, EventManagerTest_trigger_all_channels) {
EXPECT_EQ(e.button, MouseButton::LEFT_MOUSE);
return false;
};
- event_mgr.subscribe<MouseClickEvent>(mouse_handler,
- EventManager::CHANNEL_ALL);
+ event_mgr.subscribe<MouseClickEvent>(mouse_handler, EventManager::CHANNEL_ALL);
MouseClickEvent click_event{
.mouse_x = 100, .mouse_y = 200, .button = MouseButton::LEFT_MOUSE};
- event_mgr.trigger_event<MouseClickEvent>(click_event,
- EventManager::CHANNEL_ALL);
+ event_mgr.trigger_event<MouseClickEvent>(click_event, EventManager::CHANNEL_ALL);
EXPECT_TRUE(triggered);
}
@@ -77,8 +75,7 @@ TEST_F(EventManagerTest, EventManagerTest_trigger_one_channel) {
MouseClickEvent click_event{
.mouse_x = 100, .mouse_y = 200, .button = MouseButton::LEFT_MOUSE};
- event_mgr.trigger_event<MouseClickEvent>(click_event,
- EventManager::CHANNEL_ALL);
+ event_mgr.trigger_event<MouseClickEvent>(click_event, EventManager::CHANNEL_ALL);
EXPECT_FALSE(triggered);
event_mgr.trigger_event<MouseClickEvent>(click_event, test_channel);