[Lldb-commits] [lldb] r112556 - in /lldb/trunk/test: array_types/TestArrayTypes.py lldbtest.py
Johnny Chen
johnny.chen at apple.com
Mon Aug 30 16:44:39 PDT 2010
Author: johnny
Date: Mon Aug 30 18:44:39 2010
New Revision: 112556
URL: http://llvm.org/viewvc/llvm-project?rev=112556&view=rev
Log:
Added doc strings to the array_types test cases. And terminate the current
process being debugged in the TestBase.tearDown() instead of letting it continue
and finish.
Modified:
lldb/trunk/test/array_types/TestArrayTypes.py
lldb/trunk/test/lldbtest.py
Modified: lldb/trunk/test/array_types/TestArrayTypes.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/array_types/TestArrayTypes.py?rev=112556&r1=112555&r2=112556&view=diff
==============================================================================
--- lldb/trunk/test/array_types/TestArrayTypes.py (original)
+++ lldb/trunk/test/array_types/TestArrayTypes.py Mon Aug 30 18:44:39 2010
@@ -11,19 +11,23 @@
@unittest2.skipUnless(sys.platform.startswith("darwin"), "requires Darwin")
def test_with_dsym_and_run_command(self):
+ """Test 'variable list var_name' on some variables with array types."""
self.buildDsym()
self.array_types()
@unittest2.skipUnless(sys.platform.startswith("darwin"), "requires Darwin")
def test_with_dsym_and_python_api(self):
+ """Use Python APIs to inspect variables with array types."""
self.buildDsym()
self.array_types_python()
def test_with_dwarf_and_run_command(self):
+ """Test 'variable list var_name' on some variables with array types."""
self.buildDwarf()
self.array_types()
def test_with_dwarf_and_python_api(self):
+ """Use Python APIs to inspect variables with array types."""
self.buildDwarf()
self.array_types_python()
@@ -134,6 +138,10 @@
self.assertTrue(long(child5.GetValue(frame)) == 6,
"long_6[5] == 6")
+ # Now kill the process, and we are done.
+ rc = target.GetProcess().Kill()
+ self.assertTrue(rc.Success())
+
if __name__ == '__main__':
import atexit
Modified: lldb/trunk/test/lldbtest.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/lldbtest.py?rev=112556&r1=112555&r2=112556&view=diff
==============================================================================
--- lldb/trunk/test/lldbtest.py (original)
+++ lldb/trunk/test/lldbtest.py Mon Aug 30 18:44:39 2010
@@ -270,9 +270,9 @@
self.res = lldb.SBCommandReturnObject()
def tearDown(self):
- # Finish the inferior process, if it was "run" previously.
+ # Terminate the current process being debugged.
if self.runStarted:
- self.ci.HandleCommand("continue", self.res)
+ self.ci.HandleCommand("process kill", self.res)
del self.dbg
More information about the lldb-commits
mailing list