summaryrefslogtreecommitdiff
path: root/cpp/test/Glacier2/sessionControl/run.py
diff options
context:
space:
mode:
Diffstat (limited to 'cpp/test/Glacier2/sessionControl/run.py')
-rwxr-xr-xcpp/test/Glacier2/sessionControl/run.py24
1 files changed, 12 insertions, 12 deletions
diff --git a/cpp/test/Glacier2/sessionControl/run.py b/cpp/test/Glacier2/sessionControl/run.py
index 500ac7668bb..f4564493786 100755
--- a/cpp/test/Glacier2/sessionControl/run.py
+++ b/cpp/test/Glacier2/sessionControl/run.py
@@ -16,9 +16,9 @@ if len(head) > 0:
path = [os.path.join(head, p) for p in path]
path = [os.path.abspath(p) for p in path if os.path.exists(os.path.join(p, "scripts", "TestUtil.py")) ]
if len(path) == 0:
- raise "can't find toplevel directory!"
-sys.path.append(os.path.join(path[0]))
-from scripts import *
+ raise RuntimeError("can't find toplevel directory!")
+sys.path.append(os.path.join(path[0], "scripts"))
+import TestUtil
server = os.path.join(os.getcwd(), "server")
router = TestUtil.getGlacier2Router()
@@ -29,9 +29,10 @@ if TestUtil.appverifier:
targets = [server, client, router]
TestUtil.setAppVerifierSettings(targets)
-print "starting server...",
+sys.stdout.write("starting server... ")
+sys.stdout.flush()
serverProc = TestUtil.startServer(server)
-print "ok"
+print("ok")
args = ' --Glacier2.Client.Endpoints="default -p 12347"' + \
' --Ice.Admin.Endpoints="tcp -p 12348"' + \
@@ -40,20 +41,20 @@ args = ' --Glacier2.Client.Endpoints="default -p 12347"' + \
' --Glacier2.SessionManager="SessionManager:tcp -p 12010"' \
' --Glacier2.PermissionsVerifier="Glacier2/NullPermissionsVerifier"'
-print "starting router...",
+sys.stdout.write("starting router... ")
+sys.stdout.flush()
starterProc = TestUtil.startServer(router, args, count = 2)
-print "ok"
-
-
+print("ok")
#
# The test may sporadically fail without this slight pause.
#
time.sleep(1)
-print "starting client...",
+sys.stdout.write("starting client... ")
+sys.stdout.flush()
clientProc = TestUtil.startClient(client, startReader = False)
-print "ok"
+print("ok")
clientProc.startReader()
clientProc.waitTestSuccess()
@@ -62,4 +63,3 @@ starterProc.waitTestSuccess()
if TestUtil.appverifier:
TestUtil.appVerifierAfterTestEnd(targets)
-