diff options
author | Mark Spruiell <mes@zeroc.com> | 2012-04-24 14:16:15 -0700 |
---|---|---|
committer | Mark Spruiell <mes@zeroc.com> | 2012-04-24 14:16:15 -0700 |
commit | 943a48fc5c0a59b892eb746073c71b8dd88815e7 (patch) | |
tree | 421cfedbc60603d02e0b314d9204e9f85dd781c5 /demoscript/Freeze/casino.py | |
parent | minor fix to IcePHP getLogger (diff) | |
download | ice-943a48fc5c0a59b892eb746073c71b8dd88815e7.tar.bz2 ice-943a48fc5c0a59b892eb746073c71b8dd88815e7.tar.xz ice-943a48fc5c0a59b892eb746073c71b8dd88815e7.zip |
python 3 support
Diffstat (limited to 'demoscript/Freeze/casino.py')
-rwxr-xr-x | demoscript/Freeze/casino.py | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/demoscript/Freeze/casino.py b/demoscript/Freeze/casino.py index 4a58a0619ac..b7cbdc8902a 100755 --- a/demoscript/Freeze/casino.py +++ b/demoscript/Freeze/casino.py @@ -11,30 +11,30 @@ import sys, demoscript, signal def run(clientStr, serverStr): - print "cleaning databases...", + sys.stdout.write("cleaning databases... ") sys.stdout.flush() demoscript.Util.cleanDbDir("db") - print "ok" + print("ok") - print "starting server...", + sys.stdout.write("starting server... ") sys.stdout.flush() server = demoscript.Util.spawn(serverStr + ' --Ice.PrintAdapterReady --Freeze.Warn.Deadlocks=0') server.expect('Casino ready') - print "ok" + print("ok") - print "starting client1...", + sys.stdout.write("starting client1... ") sys.stdout.flush() client1 = demoscript.Util.spawn(clientStr) client1.expect('Retrieve bank and players... ok') - print "ok" + print("ok") - print "starting client2...", + sys.stdout.write("starting client2... ") sys.stdout.flush() client2 = demoscript.Util.spawn(clientStr) client2.expect('Retrieve bank and players... ok') - print "ok" + print("ok") - print "gambling...", + sys.stdout.write("gambling... ") sys.stdout.flush() client1.expect('All chips accounted for\? yes\nEach player buys 3,000 chips... ok\nAll chips accounted for\? yes'); server.expect('The bank has [0-9]+ outstanding chips') @@ -48,12 +48,12 @@ def run(clientStr, serverStr): client1.expect('All chips accounted for\? yes', timeout=400) client2.expect('All chips accounted for\? yes', timeout=400) - print "ok" + print("ok") - print "shutting down...", + sys.stdout.write("shutting down... ") sys.stdout.flush() client1.waitTestSuccess() client2.waitTestSuccess() server.kill(signal.SIGINT) server.waitTestSuccess() - print "ok" + print("ok") |