Skip to content

Commit

Permalink
test(notifications): fix test constructor crash
Browse files Browse the repository at this point in the history
  • Loading branch information
AndyTWF committed Nov 27, 2021
1 parent 39b691d commit aecd271
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions test/plugin/notifications/NotificationsEventHandlerTest.cpp
Expand Up @@ -20,21 +20,21 @@ namespace UKControllerPluginTest {
class NotificationsEventHandlerTest : public Test
{
public:
NotificationsEventHandlerTest() : messager(mockPlugin)
NotificationsEventHandlerTest()
: messager(mockPlugin), repository(std::make_shared<NotificationsRepository>()),
handler(std::make_shared<NotificationsEventHandler>(repository, messager))
{
repository = std::make_shared<NotificationsRepository>();
handler = std::make_shared<NotificationsEventHandler>(repository, messager);
}

std::vector<std::string> topDown = {"EGLL"};
std::shared_ptr<ControllerPosition> controller1 =
std::make_shared<ControllerPosition>(1, "EGLL_N_APP", 199.998, topDown, true, false);
std::shared_ptr<ControllerPosition> controller2 =
std::make_shared<ControllerPosition>(2, "EGLL_S_TWR", 199.998, topDown, true, false);
std::vector<std::string> topDown = {"EGLL"};
ActiveCallsign callsign = ActiveCallsign("EGLL_S_TWR", "Bobby", *controller1, true);
ActiveCallsign notUserCallsign = ActiveCallsign("EGLL_S_TWR", "Bobby", *controller1, false);
UserMessager messager;
NiceMock<MockEuroscopePluginLoopbackInterface> mockPlugin;
UserMessager messager;
std::shared_ptr<NotificationsRepository> repository;
std::shared_ptr<NotificationsEventHandler> handler;
};
Expand Down

0 comments on commit aecd271

Please sign in to comment.