diff options
Diffstat (limited to 'cpp/test/IceGrid/admin/run.py')
-rwxr-xr-x | cpp/test/IceGrid/admin/run.py | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/cpp/test/IceGrid/admin/run.py b/cpp/test/IceGrid/admin/run.py index 8bfebfaf4bf..aa7a63f38be 100755 --- a/cpp/test/IceGrid/admin/run.py +++ b/cpp/test/IceGrid/admin/run.py @@ -20,6 +20,13 @@ if len(path) == 0: sys.path.append(path[0]) from scripts import * + +def getIceGridAdmin(): + if TestUtil.isNoServices(): + return os.path.join(TestUtil.getServiceDir(), "icegridadmin") + else: + return os.path.join(TestUtil.getCppBinDir(), "icegridadmin") + if not TestUtil.isWin32() and os.getuid() == 0: print print "*** can't run test as root ***" @@ -33,7 +40,7 @@ nodeProc = IceGridAdmin.startIceGridNode(testdir) print "starting glacier2...", sys.stdout.flush() -router = os.path.join(TestUtil.getCppBinDir(), "glacier2router") +router = TestUtil.getGlacier2Router() args = ' --Glacier2.SessionTimeout=5' + \ ' --Glacier2.Client.Endpoints="default -p 12347"' + \ ' --Glacier2.Server.Endpoints="tcp -h 127.0.0.1"' \ @@ -50,7 +57,7 @@ print "testing login with username/password...", sys.stdout.flush() # Direct registry connection with username/password -icegridadmin = os.path.join(TestUtil.getCppBinDir(), "icegridadmin") +icegridadmin = getIceGridAdmin() args = ' --Ice.Default.Locator="IceGrid/Locator:default -p 12010"' + \ ' --IceGridAdmin.Username=demo' + \ ' --IceGridAdmin.Password=dummy' @@ -79,7 +86,7 @@ if TestUtil.protocol == "ssl": sys.stdout.flush() # Direct registry connection with SSL - icegridadmin = os.path.join(TestUtil.getCppBinDir(), "icegridadmin") + icegridadmin = getIceGridAdmin() args = ' --Ice.Default.Locator="IceGrid/Locator:default -p 12010" --ssl' admin = TestUtil.startClient(icegridadmin, args, None, None, False) admin.expect('>>> ') @@ -101,7 +108,7 @@ if TestUtil.protocol == "ssl": print "testing commands...", sys.stdout.flush() -icegridadmin = os.path.join(TestUtil.getCppBinDir(), "icegridadmin") +icegridadmin = getIceGridAdmin() args = ' --Ice.Default.Locator="IceGrid/Locator:default -p 12010"' + \ ' --IceGridAdmin.Username=demo' + \ ' --IceGridAdmin.Password=dummy' |