[Lldb-commits] [lldb] r124516 - /lldb/trunk/test/dotest.py
Johnny Chen
johnny.chen at apple.com
Fri Jan 28 17:16:52 PST 2011
Author: johnny
Date: Fri Jan 28 19:16:52 2011
New Revision: 124516
URL: http://llvm.org/viewvc/llvm-project?rev=124516&view=rev
Log:
Add a "-D" option to the test driver which dumps the Python sys.path variable
to be used for the test run. Could be useful for debugging the setup of the
test environment.
Modified:
lldb/trunk/test/dotest.py
Modified: lldb/trunk/test/dotest.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/dotest.py?rev=124516&r1=124515&r2=124516&view=diff
==============================================================================
--- lldb/trunk/test/dotest.py (original)
+++ lldb/trunk/test/dotest.py Fri Jan 28 19:16:52 2011
@@ -72,6 +72,9 @@
# Delay startup in order for the debugger to attach.
delay = False
+# Dump the Python sys.path variable.
+dumpSysPath = False
+
# By default, failfast is False. Use '-F' to overwrite it.
failfast = False
@@ -123,6 +126,7 @@
-h : print this help message and exit (also --help)
-A : specify the architecture to launch for the inferior process
-C : specify the compiler used to build the inferior executable
+-D : dump the Python sys.path variable
-a : don't do lldb Python API tests
use @python_api_test to decorate a test case as lldb Python API test
+a : just do lldb Python API tests
@@ -252,6 +256,7 @@
global configFile
global count
global delay
+ global dumpSysPath
global failfast
global filterspec
global fs4all
@@ -292,6 +297,9 @@
usage()
os.environ["CC"] = sys.argv[index]
index += 1
+ elif sys.argv[index].startswith('-D'):
+ dumpSysPath = True
+ index += 1
elif sys.argv[index].startswith('-a'):
dont_do_python_api_test = True
index += 1
@@ -453,6 +461,7 @@
global rdir
global testdirs
+ global dumpSysPath
# Get the directory containing the current script.
if "DOTEST_PROFILE" in os.environ and "DOTEST_SCRIPT_DIR" in os.environ:
@@ -509,6 +518,8 @@
# This is to locate the lldb.py module. Insert it right after sys.path[0].
sys.path[1:1] = [lldbPath]
+ if dumpSysPath:
+ print "sys.path:", sys.path
def doDelay(delta):
More information about the lldb-commits
mailing list