diff options
author | Jose <jose@zeroc.com> | 2015-07-30 14:51:36 +0200 |
---|---|---|
committer | Jose <jose@zeroc.com> | 2015-07-30 14:51:36 +0200 |
commit | ae22acbf5832e5e438a91ec8dc1667daa2e42729 (patch) | |
tree | 16016483613fcdc2358c8926dc764df475a89f7d /scripts/TestUtil.py | |
parent | Nuget support (diff) | |
download | ice-ae22acbf5832e5e438a91ec8dc1667daa2e42729.tar.bz2 ice-ae22acbf5832e5e438a91ec8dc1667daa2e42729.tar.xz ice-ae22acbf5832e5e438a91ec8dc1667daa2e42729.zip |
Fixes to test script to guess build mode
Diffstat (limited to 'scripts/TestUtil.py')
-rwxr-xr-x | scripts/TestUtil.py | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/scripts/TestUtil.py b/scripts/TestUtil.py index b9e0748940d..157645b91c7 100755 --- a/scripts/TestUtil.py +++ b/scripts/TestUtil.py @@ -1791,12 +1791,13 @@ def getServiceDir(): serviceDir = "C:\\Program Files\ZeroC\Ice-" + iceVersion + "\\bin" return serviceDir -def getBuildMode(dir): +def getBuildMode(d): + if os.path.isfile(os.path.join(d, "build.txt")): + return open(os.path.join(d, "build.txt"), "r").read().strip() import glob - executables = glob.glob("*.exe") + executables = glob.glob(os.path.join(d, "*.exe")) if not executables: - print("unable to get executable information!") - sys.exit(1) + return "release" p = subprocess.Popen("dumpbin /DEPENDENTS %s" % executables[0], stdout=subprocess.PIPE, stderr=subprocess.STDOUT, shell=True) if not p or not p.stdout: print("unable to get executable information!") |