summaryrefslogtreecommitdiff
path: root/cpp/src/tests/BrokerChannelTest.cpp
diff options
context:
space:
mode:
authorGordon Sim <gsim@apache.org>2007-07-09 10:07:26 +0000
committerGordon Sim <gsim@apache.org>2007-07-09 10:07:26 +0000
commitc4bf499790c30e0c98dd560c50c64c8a27fd9b89 (patch)
treec1f439bb86e32027c1aea5ec4e78f291737e8230 /cpp/src/tests/BrokerChannelTest.cpp
parent32fe78d370e0572a5ed21ff3e84f668d8a2f2a49 (diff)
downloadqpid-python-c4bf499790c30e0c98dd560c50c64c8a27fd9b89.tar.gz
refactoring:
* separated out the connection level method handling from semantic level (session/channel level should also be separated) * reduce coupling between Connection and Channel git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@554590 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/tests/BrokerChannelTest.cpp')
-rw-r--r--cpp/src/tests/BrokerChannelTest.cpp13
1 files changed, 7 insertions, 6 deletions
diff --git a/cpp/src/tests/BrokerChannelTest.cpp b/cpp/src/tests/BrokerChannelTest.cpp
index 29ed1ae230..929105f6e3 100644
--- a/cpp/src/tests/BrokerChannelTest.cpp
+++ b/cpp/src/tests/BrokerChannelTest.cpp
@@ -154,7 +154,7 @@ class BrokerChannelTest : public CppUnit::TestCase
void testConsumerMgmt(){
Queue::shared_ptr queue(new Queue("my_queue"));
- Channel channel(connection, 0, 0, 0);
+ Channel channel(connection, 0, 0);
channel.open();
CPPUNIT_ASSERT(!channel.exists("my_consumer"));
@@ -179,7 +179,7 @@ class BrokerChannelTest : public CppUnit::TestCase
}
void testDeliveryNoAck(){
- Channel channel(connection, 7, 10000);
+ Channel channel(connection, 7);
channel.open();
const string data("abcdefghijklmn");
Message::shared_ptr msg(
@@ -209,7 +209,7 @@ class BrokerChannelTest : public CppUnit::TestCase
}
void testDeliveryAndRecovery(){
- Channel channel(connection, 7, 10000);
+ Channel channel(connection, 7);
channel.open();
const string data("abcdefghijklmn");
@@ -241,8 +241,9 @@ class BrokerChannelTest : public CppUnit::TestCase
void testStaging(){
MockMessageStore store;
- Channel channel(
- connection, 1, 1000/*framesize*/, &store, 10/*staging threshold*/);
+ connection.setFrameMax(1000);
+ connection.setStagingThreshold(10);
+ Channel channel(connection, 1, &store);
const string data[] = {"abcde", "fghij", "klmno"};
Message* msg = new BasicMessage(
@@ -335,7 +336,7 @@ class BrokerChannelTest : public CppUnit::TestCase
}
void testFlow(){
- Channel channel(connection, 7, 10000);
+ Channel channel(connection, 7);
channel.open();
//there will always be a connection-start frame
CPPUNIT_ASSERT_EQUAL((size_t) 1, handler.frames.size());