summaryrefslogtreecommitdiff
path: root/scripts/TestUtil.py
diff options
context:
space:
mode:
authorDwayne Boone <dwayne@zeroc.com>2015-03-27 13:06:55 -0230
committerDwayne Boone <dwayne@zeroc.com>2015-03-27 13:06:55 -0230
commitc7b5928bae3fc30d0a4907285b4f9d3f0b514e63 (patch)
tree696d30e89f45bf35c8c74818fa4ac3ee9cbde8b9 /scripts/TestUtil.py
parentFixed ICE-6404 - fixed objective-c make clean (diff)
downloadice-c7b5928bae3fc30d0a4907285b4f9d3f0b514e63.tar.bz2
ice-c7b5928bae3fc30d0a4907285b4f9d3f0b514e63.tar.xz
ice-c7b5928bae3fc30d0a4907285b4f9d3f0b514e63.zip
Fix to allow running IceTouch tests with "python allTests.py"
Diffstat (limited to 'scripts/TestUtil.py')
-rwxr-xr-xscripts/TestUtil.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/scripts/TestUtil.py b/scripts/TestUtil.py
index 3db18b88143..a2bd9d21cd5 100755
--- a/scripts/TestUtil.py
+++ b/scripts/TestUtil.py
@@ -283,9 +283,10 @@ toplevel = None
path = [ ".", "..", "../..", "../../..", "../../../..", "../../../../..", "../../../../../..",
"../../../../../../..", "../../../../../../../..", "../../../../../../../../.." ]
head = os.path.dirname(sys.argv[0])
-if len(head) > 0:
- # Try to find scripts/TestUtil.py or ice/scripts/TestUtil.py in parent directories
- path = [os.path.join(head, p) for p in path] + [os.path.join(head, p, "ice") for p in path]
+if len(head) == 0:
+ head = "."
+# Try to find scripts/TestUtil.py or ice/scripts/TestUtil.py in parent directories
+path = [os.path.join(head, p) for p in path] + [os.path.join(head, p, "ice") 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 RuntimeError("can't find toplevel directory!")