diff options
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test/python_api')
6 files changed, 13 insertions, 0 deletions
diff --git a/lldb/packages/Python/lldbsuite/test/python_api/debugger/TestDebuggerAPI.py b/lldb/packages/Python/lldbsuite/test/python_api/debugger/TestDebuggerAPI.py index 1cd15646f97..fcb17cbb8e7 100644 --- a/lldb/packages/Python/lldbsuite/test/python_api/debugger/TestDebuggerAPI.py +++ b/lldb/packages/Python/lldbsuite/test/python_api/debugger/TestDebuggerAPI.py @@ -34,6 +34,9 @@ class DebuggerAPITestCase(TestBase): self.dbg.SetPrompt(None) self.dbg.SetCurrentPlatform(None) self.dbg.SetCurrentPlatformSDKRoot(None) + + fresh_dbg = lldb.SBDebugger() + self.assertEquals(len(fresh_dbg), 0) @add_test_categories(['pyapi']) def test_debugger_delete_invalid_target(self): diff --git a/lldb/packages/Python/lldbsuite/test/python_api/default-constructor/sb_compileunit.py b/lldb/packages/Python/lldbsuite/test/python_api/default-constructor/sb_compileunit.py index 0c27c94b752..77fa4694b14 100644 --- a/lldb/packages/Python/lldbsuite/test/python_api/default-constructor/sb_compileunit.py +++ b/lldb/packages/Python/lldbsuite/test/python_api/default-constructor/sb_compileunit.py @@ -12,5 +12,6 @@ def fuzz_obj(obj): obj.GetLineEntryAtIndex(0xffffffff) obj.FindLineEntryIndex(0, 0xffffffff, None) obj.GetDescription(lldb.SBStream()) + len(obj) for line_entry in obj: s = str(line_entry) diff --git a/lldb/packages/Python/lldbsuite/test/python_api/default-constructor/sb_process.py b/lldb/packages/Python/lldbsuite/test/python_api/default-constructor/sb_process.py index 5a3e1e6903c..d8c441ece58 100644 --- a/lldb/packages/Python/lldbsuite/test/python_api/default-constructor/sb_process.py +++ b/lldb/packages/Python/lldbsuite/test/python_api/default-constructor/sb_process.py @@ -48,3 +48,4 @@ def fuzz_obj(obj): obj.GetNumSupportedHardwareWatchpoints(error) for thread in obj: s = str(thread) + len(obj) diff --git a/lldb/packages/Python/lldbsuite/test/python_api/default-constructor/sb_section.py b/lldb/packages/Python/lldbsuite/test/python_api/default-constructor/sb_section.py index 5e25e94d017..4b00276fb4b 100644 --- a/lldb/packages/Python/lldbsuite/test/python_api/default-constructor/sb_section.py +++ b/lldb/packages/Python/lldbsuite/test/python_api/default-constructor/sb_section.py @@ -21,3 +21,4 @@ def fuzz_obj(obj): obj.GetDescription(lldb.SBStream()) for subsec in obj: s = str(subsec) + len(obj) diff --git a/lldb/packages/Python/lldbsuite/test/python_api/default-constructor/sb_thread.py b/lldb/packages/Python/lldbsuite/test/python_api/default-constructor/sb_thread.py index 088972532f7..3234bf2625e 100644 --- a/lldb/packages/Python/lldbsuite/test/python_api/default-constructor/sb_thread.py +++ b/lldb/packages/Python/lldbsuite/test/python_api/default-constructor/sb_thread.py @@ -36,3 +36,4 @@ def fuzz_obj(obj): obj.Clear() for frame in obj: s = str(frame) + len(obj) diff --git a/lldb/packages/Python/lldbsuite/test/python_api/symbol-context/TestSymbolContext.py b/lldb/packages/Python/lldbsuite/test/python_api/symbol-context/TestSymbolContext.py index 2b783fb90e5..57988da1ed9 100644 --- a/lldb/packages/Python/lldbsuite/test/python_api/symbol-context/TestSymbolContext.py +++ b/lldb/packages/Python/lldbsuite/test/python_api/symbol-context/TestSymbolContext.py @@ -102,3 +102,9 @@ class SymbolContextAPITestCase(TestBase): self.assertTrue( function.GetName() == symbol.GetName() and symbol.GetName() == 'c', "The symbol name should be 'c'") + + sc_list = lldb.SBSymbolContextList() + sc_list.Append(context) + self.assertEqual(len(sc_list), 1) + for sc in sc_list: + self.assertEqual(lineEntry, sc.GetLineEntry()) |