[Lldb-commits] [lldb] r111536 - in /lldb/trunk/test: array_types/TestArrayTypes.py class_types/TestClassTypes.py dead-strip/TestDeadStrip.py function_types/TestFunctionTypes.py global_variables/TestGlobalVariables.py help/TestHelp.py load_unload/TestLoadUnload.py order/TestOrderFile.py persistent_variables/TestPersistentVariables.py set_values/TestSetValues.py stl/TestSTL.py struct_types/TestStructTypes.py unsigned_types/TestUnsignedTypes.py

Johnny Chen johnny.chen at apple.com
Thu Aug 19 11:17:48 PDT 2010


Author: johnny
Date: Thu Aug 19 13:17:48 2010
New Revision: 111536

URL: http://llvm.org/viewvc/llvm-project?rev=111536&view=rev
Log:
Added more informational assert message strings.

Modified:
    lldb/trunk/test/array_types/TestArrayTypes.py
    lldb/trunk/test/class_types/TestClassTypes.py
    lldb/trunk/test/dead-strip/TestDeadStrip.py
    lldb/trunk/test/function_types/TestFunctionTypes.py
    lldb/trunk/test/global_variables/TestGlobalVariables.py
    lldb/trunk/test/help/TestHelp.py
    lldb/trunk/test/load_unload/TestLoadUnload.py
    lldb/trunk/test/order/TestOrderFile.py
    lldb/trunk/test/persistent_variables/TestPersistentVariables.py
    lldb/trunk/test/set_values/TestSetValues.py
    lldb/trunk/test/stl/TestSTL.py
    lldb/trunk/test/struct_types/TestStructTypes.py
    lldb/trunk/test/unsigned_types/TestUnsignedTypes.py

Modified: lldb/trunk/test/array_types/TestArrayTypes.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/array_types/TestArrayTypes.py?rev=111536&r1=111535&r2=111536&view=diff
==============================================================================
--- lldb/trunk/test/array_types/TestArrayTypes.py (original)
+++ lldb/trunk/test/array_types/TestArrayTypes.py Thu Aug 19 13:17:48 2010
@@ -18,7 +18,7 @@
 
         # Break on line 42 inside main().
         self.ci.HandleCommand("breakpoint set -f main.c -l 42", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint set'))
         self.assertTrue(res.GetOutput().startswith(
             "Breakpoint created: 1: file ='main.c', line = 42, locations = 1"),
                         BREAKPOINT_CREATED)
@@ -44,7 +44,7 @@
         # Issue 'variable list' command on several array-type variables.
 
         self.ci.HandleCommand("variable list strings", res);
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('variable list ...'))
         output = res.GetOutput()
         self.assertTrue(output.startswith('(char *[4])') and
                         output.find('(char *) strings[0]') > 0 and
@@ -58,18 +58,18 @@
                         VARIABLES_DISPLAYED_CORRECTLY)
 
         self.ci.HandleCommand("variable list char_16", res);
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('variable list ...'))
         self.assertTrue(res.GetOutput().find('(char) char_16[0]') > 0 and
                         res.GetOutput().find('(char) char_16[15]') > 0,
                         VARIABLES_DISPLAYED_CORRECTLY)
 
         self.ci.HandleCommand("variable list ushort_matrix", res);
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('variable list ...'))
         self.assertTrue(res.GetOutput().startswith('(unsigned short [2][3])'),
                         VARIABLES_DISPLAYED_CORRECTLY)
 
         self.ci.HandleCommand("variable list long_6", res);
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('variable list ...'))
         self.assertTrue(res.GetOutput().startswith('(long [6])'),
                         VARIABLES_DISPLAYED_CORRECTLY)
 

Modified: lldb/trunk/test/class_types/TestClassTypes.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/class_types/TestClassTypes.py?rev=111536&r1=111535&r2=111536&view=diff
==============================================================================
--- lldb/trunk/test/class_types/TestClassTypes.py (original)
+++ lldb/trunk/test/class_types/TestClassTypes.py Thu Aug 19 13:17:48 2010
@@ -18,7 +18,7 @@
 
         # Break on the ctor function of class C.
         self.ci.HandleCommand("breakpoint set -f main.cpp -l 73", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint list'))
         self.assertTrue(res.GetOutput().startswith(
             "Breakpoint created: 1: file ='main.cpp', line = 73, locations = 1"),
                         BREAKPOINT_CREATED)
@@ -37,13 +37,13 @@
 
         # The breakpoint should have a hit count of 1.
         self.ci.HandleCommand("breakpoint list", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint list'))
         self.assertTrue(res.GetOutput().find(' resolved, hit count = 1') > 0,
                         BREAKPOINT_HIT_ONCE)
 
         # We should be stopped on the ctor function of class C.
         self.ci.HandleCommand("variable list this", res);
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('variable list ...'))
         self.assertTrue(res.GetOutput().startswith('(class C *const) this = '),
                         VARIABLES_DISPLAYED_CORRECTLY)
 

Modified: lldb/trunk/test/dead-strip/TestDeadStrip.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/dead-strip/TestDeadStrip.py?rev=111536&r1=111535&r2=111536&view=diff
==============================================================================
--- lldb/trunk/test/dead-strip/TestDeadStrip.py (original)
+++ lldb/trunk/test/dead-strip/TestDeadStrip.py Thu Aug 19 13:17:48 2010
@@ -20,7 +20,7 @@
 
         # Break by function name f1 (live code).
         self.ci.HandleCommand("breakpoint set -s a.out -n f1", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint set'))
         self.assertTrue(res.GetOutput().startswith(
             "Breakpoint created: 1: name = 'f1', module = a.out, locations = 1"
             ),
@@ -28,7 +28,7 @@
 
         # Break by function name f2 (dead code).
         self.ci.HandleCommand("breakpoint set -s a.out -n f2", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint set'))
         self.assertTrue(res.GetOutput().startswith(
             "Breakpoint created: 2: name = 'f2', module = a.out, locations = 0 "
             "(pending)"),
@@ -36,7 +36,7 @@
 
         # Break by function name f3 (live code).
         self.ci.HandleCommand("breakpoint set -s a.out -n f3", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint set'))
         self.assertTrue(res.GetOutput().startswith(
             "Breakpoint created: 3: name = 'f3', module = a.out, locations = 1"
             ),
@@ -49,7 +49,7 @@
         # The stop reason of the thread should be breakpoint (breakpoint #1).
         self.ci.HandleCommand("thread list", res)
         output = res.GetOutput()
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('thread list'))
         self.assertTrue(output.find('state is Stopped') > 0 and
                         output.find('main.c:20') > 0 and
                         output.find('where = a.out`f1') > 0 and
@@ -58,17 +58,17 @@
 
         # The breakpoint should have a hit count of 1.
         self.ci.HandleCommand("breakpoint list 1", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint list'))
         self.assertTrue(res.GetOutput().find(' resolved, hit count = 1') > 0,
                         BREAKPOINT_HIT_ONCE)
 
         self.ci.HandleCommand("continue", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('continue'))
 
         # The stop reason of the thread should be breakpoint (breakpoint #3).
         self.ci.HandleCommand("thread list", res)
         output = res.GetOutput()
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('thread list'))
         self.assertTrue(output.find('state is Stopped') > 0 and
                         output.find('main.c:40') > 0 and
                         output.find('where = a.out`f3') > 0 and
@@ -77,7 +77,7 @@
 
         # The breakpoint should have a hit count of 1.
         self.ci.HandleCommand("breakpoint list 3", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint list'))
         self.assertTrue(res.GetOutput().find(' resolved, hit count = 1') > 0,
                         BREAKPOINT_HIT_ONCE)
 

Modified: lldb/trunk/test/function_types/TestFunctionTypes.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/function_types/TestFunctionTypes.py?rev=111536&r1=111535&r2=111536&view=diff
==============================================================================
--- lldb/trunk/test/function_types/TestFunctionTypes.py (original)
+++ lldb/trunk/test/function_types/TestFunctionTypes.py Thu Aug 19 13:17:48 2010
@@ -18,7 +18,7 @@
 
         # Break inside the main.
         self.ci.HandleCommand("breakpoint set -f main.c -l 21", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint set'))
         self.assertTrue(res.GetOutput().startswith(
             "Breakpoint created: 1: file ='main.c', line = 21, locations = 1"),
                         BREAKPOINT_CREATED)
@@ -37,13 +37,13 @@
 
         # The breakpoint should have a hit count of 1.
         self.ci.HandleCommand("breakpoint list", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint list'))
         self.assertTrue(res.GetOutput().find(' resolved, hit count = 1') > 0,
                         BREAKPOINT_HIT_ONCE)
 
         # Check that the 'callback' variable display properly.
         self.ci.HandleCommand("variable list callback", res);
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('variable list ...'))
         output = res.GetOutput()
         self.assertTrue(output.startswith('(int (*)(char const *)) callback ='),
                         VARIABLES_DISPLAYED_CORRECTLY)
@@ -52,11 +52,11 @@
         self.ci.HandleCommand("breakpoint set -n string_not_empty", res);
         self.assertTrue(res.Succeeded(), BREAKPOINT_CREATED)
         self.ci.HandleCommand("continue", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('continue'))
 
         # Check that we do indeed stop on the string_not_empty function.
         self.ci.HandleCommand("process status", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('process status'))
         output = res.GetOutput()
         #print "process status =", output
         self.assertTrue(output.find('where = a.out`string_not_empty') > 0 and

Modified: lldb/trunk/test/global_variables/TestGlobalVariables.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/global_variables/TestGlobalVariables.py?rev=111536&r1=111535&r2=111536&view=diff
==============================================================================
--- lldb/trunk/test/global_variables/TestGlobalVariables.py (original)
+++ lldb/trunk/test/global_variables/TestGlobalVariables.py Thu Aug 19 13:17:48 2010
@@ -18,7 +18,7 @@
 
         # Break inside the main.
         self.ci.HandleCommand("breakpoint set -f main.c -l 20", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint set'))
         self.assertTrue(res.GetOutput().startswith(
             "Breakpoint created: 1: file ='main.c', line = 20, locations = 1"),
                         BREAKPOINT_CREATED)
@@ -37,13 +37,13 @@
 
         # The breakpoint should have a hit count of 1.
         self.ci.HandleCommand("breakpoint list", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint list'))
         self.assertTrue(res.GetOutput().find(' resolved, hit count = 1') > 0,
                         BREAKPOINT_HIT_ONCE)
 
         # Check that GLOBAL scopes are indicated for the variables.
         self.ci.HandleCommand("variable list -s -a", res);
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('variable list ...'))
         output = res.GetOutput()
         self.assertTrue(output.find('GLOBAL: g_file_static_cstr') > 0 and
                         output.find('g_file_static_cstr') > 0 and

Modified: lldb/trunk/test/help/TestHelp.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/help/TestHelp.py?rev=111536&r1=111535&r2=111536&view=diff
==============================================================================
--- lldb/trunk/test/help/TestHelp.py (original)
+++ lldb/trunk/test/help/TestHelp.py Thu Aug 19 13:17:48 2010
@@ -17,9 +17,9 @@
         """A simple test of 'help' command and its output."""
         res = lldb.SBCommandReturnObject()
         self.ci.HandleCommand("help", res)
-        self.assertTrue(res.Succeeded())
-        self.assertTrue(res.GetOutput().startswith(
-            'The following is a list of built-in, permanent debugger commands'),
+        self.assertTrue(res.Succeeded() and
+                        res.GetOutput().startswith(
+                'The following is a list of built-in, permanent debugger commands'),
                         CMD_MSG('help'))
 
     def test_help_should_not_hang_emacsshell(self):
@@ -28,9 +28,9 @@
         self.ci.HandleCommand("set term-width 0", res)
         self.assertTrue(res.Succeeded(), CMD_MSG('set term-width 0'))
         self.ci.HandleCommand("help", res)
-        self.assertTrue(res.Succeeded())
-        self.assertTrue(res.GetOutput().startswith(
-            'The following is a list of built-in, permanent debugger commands'),
+        self.assertTrue(res.Succeeded() and
+                        res.GetOutput().startswith(
+                'The following is a list of built-in, permanent debugger commands'),
                         CMD_MSG('help'))
 
 

Modified: lldb/trunk/test/load_unload/TestLoadUnload.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/load_unload/TestLoadUnload.py?rev=111536&r1=111535&r2=111536&view=diff
==============================================================================
--- lldb/trunk/test/load_unload/TestLoadUnload.py (original)
+++ lldb/trunk/test/load_unload/TestLoadUnload.py Thu Aug 19 13:17:48 2010
@@ -20,7 +20,7 @@
 
         # Break by function name a_function (not yet loaded).
         self.ci.HandleCommand("breakpoint set -n a_function", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint set'))
         self.assertTrue(res.GetOutput().startswith(
             "Breakpoint created: 1: name = 'a_function', locations = 0 "
             "(pending)"
@@ -43,7 +43,7 @@
 
         # The breakpoint should have a hit count of 1.
         self.ci.HandleCommand("breakpoint list", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint list'))
         self.assertTrue(res.GetOutput().find(' resolved, hit count = 1') > 0,
                         BREAKPOINT_HIT_ONCE)
 

Modified: lldb/trunk/test/order/TestOrderFile.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/order/TestOrderFile.py?rev=111536&r1=111535&r2=111536&view=diff
==============================================================================
--- lldb/trunk/test/order/TestOrderFile.py (original)
+++ lldb/trunk/test/order/TestOrderFile.py Thu Aug 19 13:17:48 2010
@@ -21,7 +21,7 @@
 
         # Test that the debug symbols have Function f3 before Function f1.
         self.ci.HandleCommand("image dump symtab a.out", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('image dump'))
         output = res.GetOutput()
         mo_f3 = re.search("Function +.+f3", output)
         mo_f1 = re.search("Function +.+f1", output)

Modified: lldb/trunk/test/persistent_variables/TestPersistentVariables.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/persistent_variables/TestPersistentVariables.py?rev=111536&r1=111535&r2=111536&view=diff
==============================================================================
--- lldb/trunk/test/persistent_variables/TestPersistentVariables.py (original)
+++ lldb/trunk/test/persistent_variables/TestPersistentVariables.py Thu Aug 19 13:17:48 2010
@@ -19,7 +19,7 @@
         self.assertTrue(res.Succeeded(), CURRENT_EXECUTABLE_SET)
 
         self.ci.HandleCommand("breakpoint set --name main", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint set'))
 
         self.ci.HandleCommand("run", res)
         self.runStarted = True
@@ -47,10 +47,6 @@
         #print res.GetOutput()
         # $3 = (int)14
 
-        self.ci.HandleCommand("continue", res)
-        self.ci.HandleCommand("quit", res)
-        self.runStarted = False
-
 
 if __name__ == '__main__':
     import atexit

Modified: lldb/trunk/test/set_values/TestSetValues.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/set_values/TestSetValues.py?rev=111536&r1=111535&r2=111536&view=diff
==============================================================================
--- lldb/trunk/test/set_values/TestSetValues.py (original)
+++ lldb/trunk/test/set_values/TestSetValues.py Thu Aug 19 13:17:48 2010
@@ -18,27 +18,27 @@
 
         # Set breakpoints on several places to set program variables.
         self.ci.HandleCommand("breakpoint set -f main.c -l 15", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint set'))
         self.assertTrue(res.GetOutput().startswith(
             "Breakpoint created: 1: file ='main.c', line = 15, locations = 1"),
                         BREAKPOINT_CREATED)
         self.ci.HandleCommand("breakpoint set -f main.c -l 36", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint set'))
         self.assertTrue(res.GetOutput().startswith(
             "Breakpoint created: 2: file ='main.c', line = 36, locations = 1"),
                         BREAKPOINT_CREATED)
         self.ci.HandleCommand("breakpoint set -f main.c -l 57", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint set'))
         self.assertTrue(res.GetOutput().startswith(
             "Breakpoint created: 3: file ='main.c', line = 57, locations = 1"),
                         BREAKPOINT_CREATED)
         self.ci.HandleCommand("breakpoint set -f main.c -l 78", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint set'))
         self.assertTrue(res.GetOutput().startswith(
             "Breakpoint created: 4: file ='main.c', line = 78, locations = 1"),
                         BREAKPOINT_CREATED)
         self.ci.HandleCommand("breakpoint set -f main.c -l 85", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint set'))
         self.assertTrue(res.GetOutput().startswith(
             "Breakpoint created: 5: file ='main.c', line = 85, locations = 1"),
                         BREAKPOINT_CREATED)
@@ -57,26 +57,26 @@
 
         # The breakpoint should have a hit count of 1.
         self.ci.HandleCommand("breakpoint list", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint list'))
         self.assertTrue(res.GetOutput().find(' resolved, hit count = 1') > 0,
                         BREAKPOINT_HIT_ONCE)
 
         # main.c:15
         # Check that 'variable list' displays the correct data type and value.
         self.ci.HandleCommand("variable list", res);
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('variable list'))
         self.assertTrue(res.GetOutput().startswith("i = (char) 'a'"),
                         VARIABLES_DISPLAYED_CORRECTLY)
         # TODO:
         # Now set variable 'i' and check that it is correctly displayed.
 
         self.ci.HandleCommand("continue", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('continue'))
 
         # main.c:36
         # Check that 'variable list' displays the correct data type and value.
         self.ci.HandleCommand("variable list", res);
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('variable list'))
         self.assertTrue(res.GetOutput().startswith(
                 "i = (short unsigned int) 0x0021"),
                         VARIABLES_DISPLAYED_CORRECTLY)
@@ -84,36 +84,36 @@
         # Now set variable 'i' and check that it is correctly displayed.
 
         self.ci.HandleCommand("continue", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('continue'))
 
         # main.c:57
         # Check that 'variable list' displays the correct data type and value.
         self.ci.HandleCommand("variable list", res);
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('variable list'))
         self.assertTrue(res.GetOutput().startswith("i = (long int) 33"),
                         VARIABLES_DISPLAYED_CORRECTLY)
         # TODO:
         # Now set variable 'i' and check that it is correctly displayed.
 
         self.ci.HandleCommand("continue", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('continue'))
 
         # main.c:78
         # Check that 'variable list' displays the correct data type and value.
         self.ci.HandleCommand("variable list", res);
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('variable list'))
         self.assertTrue(res.GetOutput().startswith("i = (double) 3.14159"),
                         VARIABLES_DISPLAYED_CORRECTLY)
         # TODO:
         # Now set variable 'i' and check that it is correctly displayed.
 
         self.ci.HandleCommand("continue", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('continue'))
 
         # main.c:85
         # Check that 'variable list' displays the correct data type and value.
         self.ci.HandleCommand("variable list", res);
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('variable list'))
         self.assertTrue(res.GetOutput().startswith("i = (long double) "),
                         VARIABLES_DISPLAYED_CORRECTLY)
         # TODO:

Modified: lldb/trunk/test/stl/TestSTL.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/stl/TestSTL.py?rev=111536&r1=111535&r2=111536&view=diff
==============================================================================
--- lldb/trunk/test/stl/TestSTL.py (original)
+++ lldb/trunk/test/stl/TestSTL.py Thu Aug 19 13:17:48 2010
@@ -24,7 +24,7 @@
 
         # Break on line 13 of main.cpp.
         self.ci.HandleCommand("breakpoint set -f main.cpp -l 13", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint set'))
         self.assertTrue(res.GetOutput().startswith(
             "Breakpoint created: 1: file ='main.cpp', line = 13, locations = 1"
             ),
@@ -37,7 +37,7 @@
         # Stop at 'std::string hello_world ("Hello World!");'.
         self.ci.HandleCommand("thread list", res)
         #print "thread list ->", res.GetOutput()
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('thread list'))
         output = res.GetOutput()
         self.assertTrue(output.find('main.cpp:13') > 0 and
                         output.find('stop reason = breakpoint') > 0,
@@ -45,7 +45,7 @@
 
         # The breakpoint should have a hit count of 1.
         self.ci.HandleCommand("breakpoint list", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint list'))
         self.assertTrue(res.GetOutput().find(' resolved, hit count = 1') > 0,
                         BREAKPOINT_HIT_ONCE)
 
@@ -61,7 +61,7 @@
 
         self.ci.HandleCommand("thread backtrace", res)
         print "thread backtrace:", res.GetOutput()
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('thread backtarce'))
         output = res.GetOutput()
         self.assertTrue(output.find('[inlined]') > 0 and
                         output.find('basic_string.h'),

Modified: lldb/trunk/test/struct_types/TestStructTypes.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/struct_types/TestStructTypes.py?rev=111536&r1=111535&r2=111536&view=diff
==============================================================================
--- lldb/trunk/test/struct_types/TestStructTypes.py (original)
+++ lldb/trunk/test/struct_types/TestStructTypes.py Thu Aug 19 13:17:48 2010
@@ -22,7 +22,7 @@
 
         # Break on the ctor function of class C.
         self.ci.HandleCommand("breakpoint set -f main.c -l 14", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint set'))
         self.assertTrue(res.GetOutput().startswith(
             "Breakpoint created: 1: file ='main.c', line = 14, locations = 1"),
                         BREAKPOINT_CREATED)
@@ -35,7 +35,7 @@
         # function where the original breakpoint was attempted.
         self.ci.HandleCommand("thread backtrace", res)
         #print "thread backtrace ->", res.GetOutput()
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('thread backtarce'))
         output = res.GetOutput()
         self.assertTrue(output.find('main.c:20') > 0 and
                         output.find('stop reason = breakpoint') > 0,

Modified: lldb/trunk/test/unsigned_types/TestUnsignedTypes.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/unsigned_types/TestUnsignedTypes.py?rev=111536&r1=111535&r2=111536&view=diff
==============================================================================
--- lldb/trunk/test/unsigned_types/TestUnsignedTypes.py (original)
+++ lldb/trunk/test/unsigned_types/TestUnsignedTypes.py Thu Aug 19 13:17:48 2010
@@ -21,7 +21,7 @@
 
         # Break on line 19 in main() aftre the variables are assigned values.
         self.ci.HandleCommand("breakpoint set -f main.cpp -l 19", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint set'))
         self.assertTrue(res.GetOutput().startswith(
             "Breakpoint created: 1: file ='main.cpp', line = 19, locations = 1"
             ),
@@ -40,14 +40,14 @@
 
         # The breakpoint should have a hit count of 1.
         self.ci.HandleCommand("breakpoint list", res)
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('breakpoint list'))
         self.assertTrue(res.GetOutput().find(' resolved, hit count = 1') > 0,
                         BREAKPOINT_HIT_ONCE)
 
         # Test that unsigned types display correctly.
         self.ci.HandleCommand("variable list -a", res)
         #print "variable list -a ->", res.GetOutput()
-        self.assertTrue(res.Succeeded())
+        self.assertTrue(res.Succeeded(), CMD_MSG('variable list -a'))
         output = res.GetOutput()
         self.assertTrue(
             output.startswith("the_unsigned_char = (unsigned char) 'c'")





More information about the lldb-commits mailing list