diff options
| author | Alan Conway <aconway@apache.org> | 2007-07-05 16:08:29 +0000 |
|---|---|---|
| committer | Alan Conway <aconway@apache.org> | 2007-07-05 16:08:29 +0000 |
| commit | f8903ef9bf3767041bb3a8437c8423ea984e5893 (patch) | |
| tree | 4d350dfd5d525b14973f193053a2e8cf1ee150b4 /qpid/cpp/src/tests/Cluster_child.cpp | |
| parent | 90a3700bc22ee8edbc98431da50e55a8bf8c14b0 (diff) | |
| download | qpid-python-f8903ef9bf3767041bb3a8437c8423ea984e5893.tar.gz | |
* src/qpid/cluster/SessionFrame.cpp, .h: Wrap AMQFrame with
session UUID and direction.
* src/qpid/cluster/Cluster.cpp, .h: Use SessionFrame.
* src/qpid/framing/AMQFrame.h, .cpp: Added setBody(), inline getBody()
* src/qpid/framing/Uuid.h, .cpp: Clean up constructors, inline.
* src/qpid/framing/Buffer.h: Put/get byte*, size_T.
* src/qpid/cluster/SessionManager.cpp, .h:
- Maintain the session map.
- Handle frames from cluster, dispatch to proper channels.
- Implement HandlerUpdater for new channels and maintains
git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk@553543 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/cpp/src/tests/Cluster_child.cpp')
| -rw-r--r-- | qpid/cpp/src/tests/Cluster_child.cpp | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/qpid/cpp/src/tests/Cluster_child.cpp b/qpid/cpp/src/tests/Cluster_child.cpp index d73d2bdbc7..216afc7bca 100644 --- a/qpid/cpp/src/tests/Cluster_child.cpp +++ b/qpid/cpp/src/tests/Cluster_child.cpp @@ -33,13 +33,16 @@ static const ProtocolVersion VER; /** Chlid part of Cluster::clusterTwo test */ void clusterTwo() { TestCluster cluster("clusterTwo", "amqp::2"); - BOOST_REQUIRE(cluster.in.waitFor(1)); // Frame from parent. - BOOST_CHECK_TYPEID_EQUAL(ChannelPingBody, *cluster.in[0].getBody()); + BOOST_REQUIRE(cluster.received.waitFor(1)); // Frame from parent. + BOOST_CHECK(cluster.received[0].isIncoming); + BOOST_CHECK_TYPEID_EQUAL(ChannelPingBody, *cluster.received[0].frame.getBody()); BOOST_CHECK_EQUAL(2u, cluster.size()); // Me and parent + AMQFrame frame(VER, 1, new ChannelOkBody(VER)); - cluster.getToChains().out->handle(frame); - BOOST_REQUIRE(cluster.out.waitFor(1)); - BOOST_CHECK_TYPEID_EQUAL(ChannelOkBody, *cluster.out[0].getBody()); + cluster.getSendChains().out->handle(frame); + BOOST_REQUIRE(cluster.received.waitFor(2)); + BOOST_CHECK(!cluster.received[1].isIncoming); + BOOST_CHECK_TYPEID_EQUAL(ChannelOkBody, *cluster.received[1].frame.getBody()); } int test_main(int, char**) { |
