diff options
Diffstat (limited to 'Swift/Controllers/UnitTest')
-rw-r--r-- | Swift/Controllers/UnitTest/MockMainWindow.h | 3 | ||||
-rw-r--r-- | Swift/Controllers/UnitTest/RosterControllerTest.cpp | 6 |
2 files changed, 7 insertions, 2 deletions
diff --git a/Swift/Controllers/UnitTest/MockMainWindow.h b/Swift/Controllers/UnitTest/MockMainWindow.h index 3d786d9..79c148a 100644 --- a/Swift/Controllers/UnitTest/MockMainWindow.h +++ b/Swift/Controllers/UnitTest/MockMainWindow.h @@ -15,7 +15,8 @@ namespace Swift { MockMainWindow() {}; virtual ~MockMainWindow() {}; virtual void setRosterModel(Roster* roster) {this->roster = roster;}; - virtual void setMyName(const String& /*name*/) {};; + virtual void setMyNick(const String& /*name*/) {};; + virtual void setMyJID(const JID& /*jid*/) {};; virtual void setMyAvatarPath(const String& /*path*/) {}; virtual void setMyStatusText(const String& /*status*/) {}; virtual void setMyStatusType(StatusShow::Type /*type*/) {}; diff --git a/Swift/Controllers/UnitTest/RosterControllerTest.cpp b/Swift/Controllers/UnitTest/RosterControllerTest.cpp index 50419f9..df93ca5 100644 --- a/Swift/Controllers/UnitTest/RosterControllerTest.cpp +++ b/Swift/Controllers/UnitTest/RosterControllerTest.cpp @@ -30,6 +30,7 @@ #include "Swift/Controllers/UIEvents/RenameRosterItemUIEvent.h" #include "Swift/Controllers/UIEvents/RegroupRosterItemUIEvent.h" #include "Swiften/MUC/MUCRegistry.h" +#include <Swiften/Client/DummyNickManager.h> using namespace Swift; @@ -67,12 +68,14 @@ class RosterControllerTest : public CppUnit::TestFixture eventController_ = new EventController(); uiEventStream_ = new UIEventStream(); settings_ = new DummySettingsProvider(); - rosterController_ = new RosterController(jid_, xmppRoster_, avatarManager_, mainWindowFactory_, nickResolver_, presenceOracle_, subscriptionManager_, eventController_, uiEventStream_, router_, settings_); + nickManager_ = new DummyNickManager(); + rosterController_ = new RosterController(jid_, xmppRoster_, avatarManager_, mainWindowFactory_, nickManager_, nickResolver_, presenceOracle_, subscriptionManager_, eventController_, uiEventStream_, router_, settings_); mainWindow_ = mainWindowFactory_->last; }; void tearDown() { delete rosterController_; + delete nickManager_; delete nickResolver_; delete mucRegistry_; delete mainWindowFactory_; @@ -304,6 +307,7 @@ class RosterControllerTest : public CppUnit::TestFixture MUCRegistry* mucRegistry_; AvatarManager* avatarManager_; MockMainWindowFactory* mainWindowFactory_; + NickManager* nickManager_; NickResolver* nickResolver_; RosterController* rosterController_; DummyIQChannel* channel_; |