[Lldb-commits] [lldb] r144450 - /lldb/trunk/test/lang/cpp/class_types/TestClassTypes.py

Johnny Chen johnny.chen at apple.com
Fri Nov 11 18:30:23 PST 2011


Author: johnny
Date: Fri Nov 11 20:30:23 2011
New Revision: 144450

URL: http://llvm.org/viewvc/llvm-project?rev=144450&view=rev
Log:
Make the test case more robust by using line number to break, instead.

Modified:
    lldb/trunk/test/lang/cpp/class_types/TestClassTypes.py

Modified: lldb/trunk/test/lang/cpp/class_types/TestClassTypes.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/lang/cpp/class_types/TestClassTypes.py?rev=144450&r1=144449&r2=144450&view=diff
==============================================================================
--- lldb/trunk/test/lang/cpp/class_types/TestClassTypes.py (original)
+++ lldb/trunk/test/lang/cpp/class_types/TestClassTypes.py Fri Nov 11 20:30:23 2011
@@ -159,8 +159,12 @@
         # Is this a case of clang (116.1) generating bad debug info?
         #
         # Break on the ctor function of class C.
-        self.expect("breakpoint set -M C", BREAKPOINT_CREATED,
-            startstr = "Breakpoint created: 1: name = 'C'")
+        #self.expect("breakpoint set -M C", BREAKPOINT_CREATED,
+        #    startstr = "Breakpoint created: 1: name = 'C'")
+
+        # Make the test case more robust by using line number to break, instead.
+        self.expect("breakpoint set -l %d" % self.line, BREAKPOINT_CREATED,
+            startstr = "Breakpoint created")
 
         self.runCmd("run", RUN_SUCCEEDED)
 
@@ -174,6 +178,7 @@
             substrs = [' resolved, hit count = 1'])
 
         # Continue on inside the ctor() body...
+        self.runCmd("register read pc")
         self.runCmd("thread step-over")
 
         # Verify that 'frame variable this' gets the data type correct.
@@ -181,6 +186,8 @@
             substrs = ['C *'])
 
         # Verify that frame variable -T this->m_c_int behaves correctly.
+        self.runCmd("register read pc")
+        self.runCmd("expr m_c_int")
         self.expect("frame variable -T this->m_c_int", VARIABLES_DISPLAYED_CORRECTLY,
             startstr = '(int) this->m_c_int = 66')
 





More information about the lldb-commits mailing list