diff options
author | Remko Tronçon <git@el-tramo.be> | 2010-10-09 09:52:51 (GMT) |
---|---|---|
committer | Remko Tronçon <git@el-tramo.be> | 2010-10-09 14:20:47 (GMT) |
commit | c5bb67eab6f97ae0f5f7e673ff0ba9b1111191f4 (patch) | |
tree | ad17bd2ee34263af472340a839a4757859ddaea1 /Swiften/Queries/Requests/UnitTest | |
parent | 0a84186a22fd48485deed77bc067877ac332d0b4 (diff) | |
download | swift-contrib-c5bb67eab6f97ae0f5f7e673ff0ba9b1111191f4.zip swift-contrib-c5bb67eab6f97ae0f5f7e673ff0ba9b1111191f4.tar.bz2 |
Added EchoBot walkthrough example.
Diffstat (limited to 'Swiften/Queries/Requests/UnitTest')
-rw-r--r-- | Swiften/Queries/Requests/UnitTest/GetPrivateStorageRequestTest.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/Swiften/Queries/Requests/UnitTest/GetPrivateStorageRequestTest.cpp b/Swiften/Queries/Requests/UnitTest/GetPrivateStorageRequestTest.cpp index d90a114..fe8b0a0 100644 --- a/Swiften/Queries/Requests/UnitTest/GetPrivateStorageRequestTest.cpp +++ b/Swiften/Queries/Requests/UnitTest/GetPrivateStorageRequestTest.cpp @@ -45,8 +45,8 @@ class GetPrivateStorageRequestTest : public CppUnit::TestFixture } void testSend() { - GetPrivateStorageRequest<MyPayload> request(router); - request.send(); + GetPrivateStorageRequest<MyPayload>::ref request = GetPrivateStorageRequest<MyPayload>::create(router); + request->send(); CPPUNIT_ASSERT_EQUAL(1, static_cast<int>(channel->iqs_.size())); CPPUNIT_ASSERT_EQUAL(JID(), channel->iqs_[0]->getTo()); @@ -58,9 +58,9 @@ class GetPrivateStorageRequestTest : public CppUnit::TestFixture } void testHandleResponse() { - GetPrivateStorageRequest<MyPayload> testling(router); - testling.onResponse.connect(boost::bind(&GetPrivateStorageRequestTest::handleResponse, this, _1, _2)); - testling.send(); + GetPrivateStorageRequest<MyPayload>::ref testling = GetPrivateStorageRequest<MyPayload>::create(router); + testling->onResponse.connect(boost::bind(&GetPrivateStorageRequestTest::handleResponse, this, _1, _2)); + testling->send(); channel->onIQReceived(createResponse("test-id", "foo")); CPPUNIT_ASSERT_EQUAL(1, static_cast<int>(responses.size())); @@ -68,9 +68,9 @@ class GetPrivateStorageRequestTest : public CppUnit::TestFixture } void testHandleResponse_Error() { - GetPrivateStorageRequest<MyPayload> testling(router); - testling.onResponse.connect(boost::bind(&GetPrivateStorageRequestTest::handleResponse, this, _1, _2)); - testling.send(); + GetPrivateStorageRequest<MyPayload>::ref testling = GetPrivateStorageRequest<MyPayload>::create(router); + testling->onResponse.connect(boost::bind(&GetPrivateStorageRequestTest::handleResponse, this, _1, _2)); + testling->send(); channel->onIQReceived(createError("test-id")); CPPUNIT_ASSERT_EQUAL(0, static_cast<int>(responses.size())); |