diff options
author | Alan Conway <aconway@apache.org> | 2011-08-18 14:58:53 +0000 |
---|---|---|
committer | Alan Conway <aconway@apache.org> | 2011-08-18 14:58:53 +0000 |
commit | 3dbb71f39734ae769d258bb1548ba946e859a13a (patch) | |
tree | 1e0b479ab1dc37e4aef389d980d0b81e1252681d /qpid/cpp/src/tests/ClientSessionTest.cpp | |
parent | acef88b76696a58cc53e82c3000f91d489f0a382 (diff) | |
download | qpid-python-3dbb71f39734ae769d258bb1548ba946e859a13a.tar.gz |
NO-JIRA: eliminate SocketProxy from tests.
Was causing problems with changes to introduce IPv6.
In most cases this was being used unnecessarilly due to cut-and-paste of tests.
In the 2 cases it was useful, replaced by simply shutting down the broker
to simulate network failure.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1159268 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/cpp/src/tests/ClientSessionTest.cpp')
-rw-r--r-- | qpid/cpp/src/tests/ClientSessionTest.cpp | 26 |
1 files changed, 2 insertions, 24 deletions
diff --git a/qpid/cpp/src/tests/ClientSessionTest.cpp b/qpid/cpp/src/tests/ClientSessionTest.cpp index 3c0cff7350..30441cd03c 100644 --- a/qpid/cpp/src/tests/ClientSessionTest.cpp +++ b/qpid/cpp/src/tests/ClientSessionTest.cpp @@ -102,9 +102,9 @@ struct SimpleListener : public MessageListener } }; -struct ClientSessionFixture : public ProxySessionFixture +struct ClientSessionFixture : public SessionFixture { - ClientSessionFixture(Broker::Options opts = Broker::Options()) : ProxySessionFixture(opts) { + ClientSessionFixture(Broker::Options opts = Broker::Options()) : SessionFixture(opts) { session.queueDeclare(arg::queue="my-queue"); } }; @@ -150,16 +150,6 @@ QPID_AUTO_TEST_CASE(testDispatcherThread) BOOST_CHECK_EQUAL(boost::lexical_cast<string>(i), listener.messages[i].getData()); } -// FIXME aconway 2009-06-17: test for unimplemented feature, enable when implemented. -void testSuspend0Timeout() { - ClientSessionFixture fix; - fix.session.suspend(); // session has 0 timeout. - try { - fix.connection.resume(fix.session); - BOOST_FAIL("Expected InvalidArgumentException."); - } catch(const InternalErrorException&) {} -} - QPID_AUTO_TEST_CASE(testUseSuspendedError) { ClientSessionFixture fix; @@ -171,18 +161,6 @@ QPID_AUTO_TEST_CASE(testUseSuspendedError) } catch(const NotAttachedException&) {} } -// FIXME aconway 2009-06-17: test for unimplemented feature, enable when implemented. -void testSuspendResume() { - ClientSessionFixture fix; - fix.session.timeout(60); - fix.session.suspend(); - // Make sure we are still subscribed after resume. - fix.connection.resume(fix.session); - fix.session.messageTransfer(arg::content=Message("my-message", "my-queue")); - BOOST_CHECK_EQUAL("my-message", fix.subs.get("my-queue", TIME_SEC).getData()); -} - - QPID_AUTO_TEST_CASE(testSendToSelf) { ClientSessionFixture fix; SimpleListener mylistener; |