diff --git a/src/tests/usermanager.cpp b/src/tests/usermanager.cpp index cbe49747df02056f2e0868eb4519643eb0f2a83b..0bbc7fe42e69f6145f3eb37539c1f5bc6cfc4136 100644 --- a/src/tests/usermanager.cpp +++ b/src/tests/usermanager.cpp @@ -105,7 +105,7 @@ class UserManagerTest : public CPPUNIT_NS :: TestFixture, public BasicTest { response->setTo("localhost"); response->setFrom("user@localhost/resource"); response->setType(Swift::Presence::Probe); - dynamic_cast(component->getStanzaChannel())->onPresenceReceived(response); + dynamic_cast(static_cast(component->getFrontend())->getStanzaChannel())->onPresenceReceived(response); loop->processEvents(); CPPUNIT_ASSERT_EQUAL(3, (int) received.size()); @@ -124,7 +124,7 @@ class UserManagerTest : public CPPUNIT_NS :: TestFixture, public BasicTest { response->setTo("localhost"); response->setFrom("user@localhost"); response->setType(Swift::Presence::Unsubscribed); - dynamic_cast(component->getStanzaChannel())->onPresenceReceived(response); + dynamic_cast(static_cast(component->getFrontend())->getStanzaChannel())->onPresenceReceived(response); loop->processEvents(); CPPUNIT_ASSERT_EQUAL(2, (int) received.size()); @@ -137,7 +137,7 @@ class UserManagerTest : public CPPUNIT_NS :: TestFixture, public BasicTest { response->setTo("localhost"); response->setFrom("user@localhost"); response->setType(Swift::Presence::Error); - dynamic_cast(component->getStanzaChannel())->onPresenceReceived(response); + dynamic_cast(static_cast(component->getFrontend())->getStanzaChannel())->onPresenceReceived(response); loop->processEvents(); CPPUNIT_ASSERT_EQUAL(0, (int) received.size()); @@ -147,7 +147,7 @@ class UserManagerTest : public CPPUNIT_NS :: TestFixture, public BasicTest { response->setFrom("user@localhost"); response->setType(Swift::Presence::Error); response->addPayload(boost::shared_ptr(new Swift::ErrorPayload(Swift::ErrorPayload::SubscriptionRequired))); - dynamic_cast(component->getStanzaChannel())->onPresenceReceived(response); + dynamic_cast(static_cast(component->getFrontend())->getStanzaChannel())->onPresenceReceived(response); loop->processEvents(); CPPUNIT_ASSERT_EQUAL(1, (int) received.size()); @@ -161,7 +161,7 @@ class UserManagerTest : public CPPUNIT_NS :: TestFixture, public BasicTest { response->setTo("localhost"); response->setFrom("user@localhost"); response->setType(Swift::Presence::Unsubscribed); - dynamic_cast(component->getStanzaChannel())->onPresenceReceived(response); + dynamic_cast(static_cast(component->getFrontend())->getStanzaChannel())->onPresenceReceived(response); loop->processEvents(); CPPUNIT_ASSERT_EQUAL(1, (int) received.size());