diff options
author | Gordon Sim <gsim@apache.org> | 2010-01-22 10:58:20 +0000 |
---|---|---|
committer | Gordon Sim <gsim@apache.org> | 2010-01-22 10:58:20 +0000 |
commit | 94414b346e8423c7d2ced919a022867e0217fbaf (patch) | |
tree | cc33eba0e3faccba8bd910739659a41d5f162403 /qpid/cpp/src/tests/ClientSessionTest.cpp | |
parent | fa62d82fe2dfc127440de4675803d1a279807722 (diff) | |
download | qpid-python-94414b346e8423c7d2ced919a022867e0217fbaf.tar.gz |
QPID-2347: Signal deletion of queue to active subscribers via a resource-deleted exception.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@902055 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/cpp/src/tests/ClientSessionTest.cpp')
-rw-r--r-- | qpid/cpp/src/tests/ClientSessionTest.cpp | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/qpid/cpp/src/tests/ClientSessionTest.cpp b/qpid/cpp/src/tests/ClientSessionTest.cpp index 8ce5d85632..e8cdb1f232 100644 --- a/qpid/cpp/src/tests/ClientSessionTest.cpp +++ b/qpid/cpp/src/tests/ClientSessionTest.cpp @@ -629,6 +629,19 @@ QPID_AUTO_TEST_CASE(testGetConnectionFromSession) { BOOST_CHECK(!fix.subs.get(got, "a")); } + +QPID_AUTO_TEST_CASE(testQueueDeleted) +{ + ClientSessionFixture fix; + fix.session.queueDeclare(arg::queue="my-queue"); + LocalQueue queue; + fix.subs.subscribe(queue, "my-queue"); + + ScopedSuppressLogging sl; + fix.session.queueDelete(arg::queue="my-queue"); + BOOST_CHECK_THROW(queue.get(1*qpid::sys::TIME_SEC), qpid::framing::ResourceDeletedException); +} + QPID_AUTO_TEST_SUITE_END() }} // namespace qpid::tests |