summaryrefslogtreecommitdiff
path: root/cpp/test/Ice/udp/AllTests.cpp
diff options
context:
space:
mode:
authorBenoit Foucher <benoit@zeroc.com>2009-01-22 15:19:02 +0100
committerBenoit Foucher <benoit@zeroc.com>2009-01-22 15:19:02 +0100
commit3994b371119ba308c6c4f27475c1b16a1fc518eb (patch)
tree476d2e9180d79e3910430b1396431d93c43bb180 /cpp/test/Ice/udp/AllTests.cpp
parentMore fixes for bug3504 and fixed bug3506 (diff)
downloadice-3994b371119ba308c6c4f27475c1b16a1fc518eb.tar.bz2
ice-3994b371119ba308c6c4f27475c1b16a1fc518eb.tar.xz
ice-3994b371119ba308c6c4f27475c1b16a1fc518eb.zip
Fixed bug 3484 & 3604
Diffstat (limited to 'cpp/test/Ice/udp/AllTests.cpp')
-rw-r--r--cpp/test/Ice/udp/AllTests.cpp32
1 files changed, 32 insertions, 0 deletions
diff --git a/cpp/test/Ice/udp/AllTests.cpp b/cpp/test/Ice/udp/AllTests.cpp
index 41a21e287d7..7b05acad659 100644
--- a/cpp/test/Ice/udp/AllTests.cpp
+++ b/cpp/test/Ice/udp/AllTests.cpp
@@ -79,6 +79,38 @@ allTests(const CommunicatorPtr& communicator)
obj->ping(reply);
bool ret = replyI->waitReply(3, IceUtil::Time::seconds(2));
test(ret == true);
+
+ Test::ByteSeq seq;
+ try
+ {
+ seq.resize(1024);
+ while(true)
+ {
+ seq.resize(seq.size() * 2 + 10);
+ replyI->reset();
+ obj->sendByteSeq(seq, reply);
+ replyI->waitReply(1, IceUtil::Time::seconds(10));
+ }
+ }
+ catch(const DatagramLimitException&)
+ {
+ test(seq.size() > 16384);
+ }
+
+ communicator->getProperties()->setProperty("Ice.UDP.SndSize", "64000");
+ seq.resize(50000);
+ try
+ {
+ replyI->reset();
+ obj->sendByteSeq(seq, reply);
+ test(!replyI->waitReply(1, IceUtil::Time::milliSeconds(500)));
+ }
+ catch(const Ice::LocalException& ex)
+ {
+ cerr << ex << endl;
+ test(false);
+ }
+
cout << "ok" << endl;
cout << "testing udp multicast... " << flush;