summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lldb/test/array_types/TestArrayTypes.py5
-rw-r--r--lldb/test/class_types/TestClassTypes.py4
2 files changed, 9 insertions, 0 deletions
diff --git a/lldb/test/array_types/TestArrayTypes.py b/lldb/test/array_types/TestArrayTypes.py
index 7bf5aba1d17..a7cb6a705b1 100644
--- a/lldb/test/array_types/TestArrayTypes.py
+++ b/lldb/test/array_types/TestArrayTypes.py
@@ -29,6 +29,7 @@ class TestArrayTypes(unittest.TestCase):
self.ci.HandleCommand("file " + exe, res)
self.assertTrue(res.Succeeded())
+ # Break on line 42 inside main().
self.ci.HandleCommand("breakpoint set -f main.c -l 42", res)
self.assertTrue(res.Succeeded())
self.assertTrue(res.GetOutput().startswith(
@@ -37,15 +38,19 @@ class TestArrayTypes(unittest.TestCase):
self.ci.HandleCommand("run", res)
self.assertTrue(res.Succeeded())
+ # The breakpoint should have a hit count of 1.
self.ci.HandleCommand("breakpoint list", res)
self.assertTrue(res.Succeeded())
self.assertTrue(res.GetOutput().find('resolved, hit count = 1'))
+ # And the stop reason of the thread should be breakpoint.
self.ci.HandleCommand("thread list", res)
self.assertTrue(res.Succeeded())
self.assertTrue(res.GetOutput().find('state is Stopped') and
res.GetOutput().find('stop reason = breakpoint'))
+ # Issue 'variable list' command on several array-type variables.
+
self.ci.HandleCommand("variable list strings", res);
self.assertTrue(res.Succeeded())
output = res.GetOutput()
diff --git a/lldb/test/class_types/TestClassTypes.py b/lldb/test/class_types/TestClassTypes.py
index 93f9fb06147..a02782e8479 100644
--- a/lldb/test/class_types/TestClassTypes.py
+++ b/lldb/test/class_types/TestClassTypes.py
@@ -29,6 +29,7 @@ class TestClassTypes(unittest.TestCase):
self.ci.HandleCommand("file " + exe, res)
self.assertTrue(res.Succeeded())
+ # 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.GetOutput().startswith(
@@ -37,15 +38,18 @@ class TestClassTypes(unittest.TestCase):
self.ci.HandleCommand("run", res)
self.assertTrue(res.Succeeded())
+ # The breakpoint should have a hit count of 1.
self.ci.HandleCommand("breakpoint list", res)
self.assertTrue(res.Succeeded())
self.assertTrue(res.GetOutput().find('resolved, hit count = 1'))
+ # And the stop reason of the thread should be breakpoint.
self.ci.HandleCommand("thread list", res)
self.assertTrue(res.Succeeded())
self.assertTrue(res.GetOutput().find('state is Stopped') and
res.GetOutput().find('stop reason = breakpoint'))
+ # 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.GetOutput().startswith('(class C *const) this = '))
OpenPOWER on IntegriCloud