summaryrefslogtreecommitdiff
path: root/cpp
diff options
context:
space:
mode:
Diffstat (limited to 'cpp')
-rw-r--r--cpp/config/TestUtil.py4
-rw-r--r--cpp/test/Glacier/starter/Client.cpp8
-rwxr-xr-xcpp/test/Glacier/starter/run.py2
3 files changed, 11 insertions, 3 deletions
diff --git a/cpp/config/TestUtil.py b/cpp/config/TestUtil.py
index b8765f7adcc..b9b80624ffb 100644
--- a/cpp/config/TestUtil.py
+++ b/cpp/config/TestUtil.py
@@ -132,7 +132,7 @@ def clientServerTest(toplevel, name):
break;
print output,
-def clientServerHybridTest(toplevel, name):
+def mixedClientServerTest(toplevel, name):
testdir = os.path.join(toplevel, "test", name)
server = os.path.join(testdir, "server")
@@ -149,6 +149,8 @@ def clientServerHybridTest(toplevel, name):
print "starting client...",
clientPipe = os.popen(client + updatedClientOptions)
+ getServerPid(clientPipe)
+ getAdapterReady(clientPipe)
output = clientPipe.readline()
if not output:
print "failed!"
diff --git a/cpp/test/Glacier/starter/Client.cpp b/cpp/test/Glacier/starter/Client.cpp
index 389734615ae..92b85caa522 100644
--- a/cpp/test/Glacier/starter/Client.cpp
+++ b/cpp/test/Glacier/starter/Client.cpp
@@ -38,9 +38,15 @@ CallbackClient::run(int argc, char* argv[])
{
string ref;
- cout << "creating and activating callback receiver adapter... " << flush;
ObjectAdapterPtr adapter = communicator()->createObjectAdapterWithEndpoints("CallbackReceiverAdapter", "default");
adapter->activate();
+ // Put the print statement after activate(), so that if
+ // Ice.PrintAdapterReady is set, the "ready" is the first output
+ // from the client, and not the print statement below. Otherwise
+ // the Python test scripts will be confused, as they expect the
+ // "ready" from the Object Adapter to be the first thing that is
+ // printed.
+ cout << "creating and activating callback receiver adapter... " << flush;
cout << "ok" << endl;
cout << "creating and adding callback receiver object... " << flush;
diff --git a/cpp/test/Glacier/starter/run.py b/cpp/test/Glacier/starter/run.py
index b39c3c85ccf..09357804665 100755
--- a/cpp/test/Glacier/starter/run.py
+++ b/cpp/test/Glacier/starter/run.py
@@ -54,7 +54,7 @@ TestUtil.getAdapterReady(starterPipe)
print "ok"
name = os.path.join("Glacier", "starter")
-TestUtil.clientServerHybridTest(toplevel, name)
+TestUtil.mixedClientServerTest(toplevel, name)
print "shutting down glacier starter...",
TestUtil.killServers() # TODO: Graceful shutdown