diff options
author | Benoit Foucher <benoit@zeroc.com> | 2018-03-20 21:18:10 +0100 |
---|---|---|
committer | Benoit Foucher <benoit@zeroc.com> | 2018-03-20 21:18:25 +0100 |
commit | a157ae70831fd23d0c27f118d108d7f13bce3b45 (patch) | |
tree | ae65d3dbfff9ef416e94e49a22d1a826d95a9e0c /cpp/test/Ice/acm/AllTests.cpp | |
parent | Run JavaScript es6 test suite with Edge (diff) | |
download | ice-a157ae70831fd23d0c27f118d108d7f13bce3b45.tar.bz2 ice-a157ae70831fd23d0c27f118d108d7f13bce3b45.tar.xz ice-a157ae70831fd23d0c27f118d108d7f13bce3b45.zip |
Added sanity checks for ACM timeout value (ICE-8749)
Diffstat (limited to 'cpp/test/Ice/acm/AllTests.cpp')
-rw-r--r-- | cpp/test/Ice/acm/AllTests.cpp | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/cpp/test/Ice/acm/AllTests.cpp b/cpp/test/Ice/acm/AllTests.cpp index d362b3b6bc6..94b8c0da84d 100644 --- a/cpp/test/Ice/acm/AllTests.cpp +++ b/cpp/test/Ice/acm/AllTests.cpp @@ -314,7 +314,7 @@ public: proxy->sleep(4); Lock sync(*this); - test(_heartbeat >= 6); + test(_heartbeat >= 4); } }; @@ -618,6 +618,21 @@ public: { Ice::ConnectionPtr con = proxy->ice_getConnection(); + try + { + con->setACM(-19, IceUtil::None, IceUtil::None); + test(false); + } +#ifndef ICE_CPP11_MAPPING + catch(const IceUtil::IllegalArgumentException&) + { + } +#else + catch(const invalid_argument&) + { + } +#endif + Ice::ACM acm; acm = con->getACM(); test(acm.timeout == 15); |