diff options
Diffstat (limited to 'cpp/test/Ice/invoke/AllTests.cpp')
-rw-r--r-- | cpp/test/Ice/invoke/AllTests.cpp | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/cpp/test/Ice/invoke/AllTests.cpp b/cpp/test/Ice/invoke/AllTests.cpp index 66058b20230..d615ffb37a8 100644 --- a/cpp/test/Ice/invoke/AllTests.cpp +++ b/cpp/test/Ice/invoke/AllTests.cpp @@ -380,6 +380,14 @@ allTests(Test::TestHelper* helper) } } + { + // Oneway operation with a oneway proxy must return empty encapsulation. + Ice::ByteSeq inEncaps, outEncaps; + bool returnValue = oneway->ice_invoke("opOneway", Ice::ICE_ENUM(OperationMode, Normal), inEncaps, outEncaps); + test(returnValue); + test(outEncaps.size() == 0); // Empty encapsulation + } + cout << "ok" << endl; cout << "testing asynchronous ice_invoke... " << flush; @@ -439,9 +447,20 @@ allTests(Test::TestHelper* helper) // { + // Oneway operation with a oneway proxy must return empty encapsulation. Ice::ByteSeq inEncaps, outEncaps; + bool returnValue = oneway->ice_invoke("opOneway", Ice::OperationMode::Normal, inEncaps, outEncaps); + test(returnValue); + test(outEncaps.size() == 0); // Empty encapsulation + } + + { + // Oneway operation with a oneway proxy must return empty encapsulation. + Ice::ByteSeq inEncaps; auto completed = oneway->ice_invokeAsync("opOneway", Ice::OperationMode::Normal, inEncaps); - test(completed.get().returnValue); + auto result = completed.get(); + test(result.returnValue); + test(result.outParams.size() == 0); // Empty encapsulation } { @@ -646,6 +665,8 @@ allTests(Test::TestHelper* helper) { test(false); } + test(result); + test(outEncaps.size() == 0); // Empty encapsulation Ice::OutputStream out(communicator); out.startEncapsulation(); |