summaryrefslogtreecommitdiffstats
path: root/lldb/test/python_api/lldbutil
diff options
context:
space:
mode:
Diffstat (limited to 'lldb/test/python_api/lldbutil')
-rw-r--r--lldb/test/python_api/lldbutil/frame/TestFrameUtils.py5
-rw-r--r--lldb/test/python_api/lldbutil/iter/TestLLDBIterator.py27
-rw-r--r--lldb/test/python_api/lldbutil/iter/TestRegistersIterator.py5
-rw-r--r--lldb/test/python_api/lldbutil/process/TestPrintStackTraces.py7
4 files changed, 12 insertions, 32 deletions
diff --git a/lldb/test/python_api/lldbutil/frame/TestFrameUtils.py b/lldb/test/python_api/lldbutil/frame/TestFrameUtils.py
index 22db4a4be36..4b0c460ad69 100644
--- a/lldb/test/python_api/lldbutil/frame/TestFrameUtils.py
+++ b/lldb/test/python_api/lldbutil/frame/TestFrameUtils.py
@@ -21,10 +21,7 @@ class FrameUtilsTestCase(TestBase):
@python_api_test
def test_frame_utils(self):
"""Test utility functions for the frame object."""
- self.buildDefault()
- self.frame_utils()
-
- def frame_utils(self):
+ self.build()
exe = os.path.join(os.getcwd(), "a.out")
target = self.dbg.CreateTarget(exe)
diff --git a/lldb/test/python_api/lldbutil/iter/TestLLDBIterator.py b/lldb/test/python_api/lldbutil/iter/TestLLDBIterator.py
index 4d32d6d997d..124f7031597 100644
--- a/lldb/test/python_api/lldbutil/iter/TestLLDBIterator.py
+++ b/lldb/test/python_api/lldbutil/iter/TestLLDBIterator.py
@@ -22,22 +22,7 @@ class LLDBIteratorTestCase(TestBase):
@python_api_test
def test_lldb_iter_module(self):
"""Test module_iter works correctly for SBTarget -> SBModule."""
- self.buildDefault()
- self.lldb_iter_module()
-
- @python_api_test
- def test_lldb_iter_breakpoint(self):
- """Test breakpoint_iter works correctly for SBTarget -> SBBreakpoint."""
- self.buildDefault()
- self.lldb_iter_breakpoint()
-
- @python_api_test
- def test_lldb_iter_frame(self):
- """Test iterator works correctly for SBProcess->SBThread->SBFrame."""
- self.buildDefault()
- self.lldb_iter_frame()
-
- def lldb_iter_module(self):
+ self.build()
exe = os.path.join(os.getcwd(), "a.out")
target = self.dbg.CreateTarget(exe)
@@ -68,7 +53,10 @@ class LLDBIteratorTestCase(TestBase):
self.assertTrue(yours[i] == mine[i],
"UUID+FileSpec of yours[{0}] and mine[{0}] matches".format(i))
- def lldb_iter_breakpoint(self):
+ @python_api_test
+ def test_lldb_iter_breakpoint(self):
+ """Test breakpoint_iter works correctly for SBTarget -> SBBreakpoint."""
+ self.build()
exe = os.path.join(os.getcwd(), "a.out")
target = self.dbg.CreateTarget(exe)
@@ -97,7 +85,10 @@ class LLDBIteratorTestCase(TestBase):
self.assertTrue(yours[i] == mine[i],
"ID of yours[{0}] and mine[{0}] matches".format(i))
- def lldb_iter_frame(self):
+ @python_api_test
+ def test_lldb_iter_frame(self):
+ """Test iterator works correctly for SBProcess->SBThread->SBFrame."""
+ self.build()
exe = os.path.join(os.getcwd(), "a.out")
target = self.dbg.CreateTarget(exe)
diff --git a/lldb/test/python_api/lldbutil/iter/TestRegistersIterator.py b/lldb/test/python_api/lldbutil/iter/TestRegistersIterator.py
index 4dc5dbe7aa6..32d660e5950 100644
--- a/lldb/test/python_api/lldbutil/iter/TestRegistersIterator.py
+++ b/lldb/test/python_api/lldbutil/iter/TestRegistersIterator.py
@@ -22,10 +22,7 @@ class RegistersIteratorTestCase(TestBase):
@expectedFailureWindows # Test crashes
def test_iter_registers(self):
"""Test iterator works correctly for lldbutil.iter_registers()."""
- self.buildDefault()
- self.iter_registers()
-
- def iter_registers(self):
+ self.build()
exe = os.path.join(os.getcwd(), "a.out")
target = self.dbg.CreateTarget(exe)
diff --git a/lldb/test/python_api/lldbutil/process/TestPrintStackTraces.py b/lldb/test/python_api/lldbutil/process/TestPrintStackTraces.py
index cd13d688e19..09945f5cbe5 100644
--- a/lldb/test/python_api/lldbutil/process/TestPrintStackTraces.py
+++ b/lldb/test/python_api/lldbutil/process/TestPrintStackTraces.py
@@ -23,12 +23,7 @@ class ThreadsStackTracesTestCase(TestBase):
@python_api_test
def test_stack_traces(self):
"""Test SBprocess and SBThread APIs with printing of the stack traces."""
- self.buildDefault()
- self.break_and_print_stacktraces()
-
- def break_and_print_stacktraces(self):
- """Break at main.cpp:68 and do a threads dump"""
-
+ self.build()
exe = os.path.join(os.getcwd(), "a.out")
target = self.dbg.CreateTarget(exe)
OpenPOWER on IntegriCloud