diff options
Diffstat (limited to 'lldb/test/python_api/lldbutil')
4 files changed, 8 insertions, 31 deletions
diff --git a/lldb/test/python_api/lldbutil/frame/TestFrameUtils.py b/lldb/test/python_api/lldbutil/frame/TestFrameUtils.py index 4b0c460ad69..28121365b75 100644 --- a/lldb/test/python_api/lldbutil/frame/TestFrameUtils.py +++ b/lldb/test/python_api/lldbutil/frame/TestFrameUtils.py @@ -2,8 +2,9 @@ Test utility functions for the frame object. """ +import lldb_shared + import os -import unittest2 import lldb from lldbtest import * @@ -54,10 +55,3 @@ class FrameUtilsTestCase(TestBase): lldbutil.print_stacktrace(thread) print "Current frame: %s" % frame0_args print "Parent frame: %s" % parent_args - - -if __name__ == '__main__': - import atexit - lldb.SBDebugger.Initialize() - atexit.register(lambda: lldb.SBDebugger.Terminate()) - unittest2.main() diff --git a/lldb/test/python_api/lldbutil/iter/TestLLDBIterator.py b/lldb/test/python_api/lldbutil/iter/TestLLDBIterator.py index 124f7031597..c8ee37c1661 100644 --- a/lldb/test/python_api/lldbutil/iter/TestLLDBIterator.py +++ b/lldb/test/python_api/lldbutil/iter/TestLLDBIterator.py @@ -2,9 +2,10 @@ Test the iteration protocol for some lldb container objects. """ +import lldb_shared + import os, time import re -import unittest2 import lldb from lldbtest import * @@ -117,9 +118,3 @@ class LLDBIteratorTestCase(TestBase): print frame self.assertTrue(stopped_due_to_breakpoint) - -if __name__ == '__main__': - import atexit - lldb.SBDebugger.Initialize() - atexit.register(lambda: lldb.SBDebugger.Terminate()) - unittest2.main() diff --git a/lldb/test/python_api/lldbutil/iter/TestRegistersIterator.py b/lldb/test/python_api/lldbutil/iter/TestRegistersIterator.py index 32d660e5950..0a49bc2fe4a 100644 --- a/lldb/test/python_api/lldbutil/iter/TestRegistersIterator.py +++ b/lldb/test/python_api/lldbutil/iter/TestRegistersIterator.py @@ -2,9 +2,10 @@ Test the iteration protocol for frame registers. """ +import lldb_shared + import os, time import re -import unittest2 import lldb from lldbtest import * @@ -89,10 +90,3 @@ class RegistersIteratorTestCase(TestBase): # We've finished dumping the registers for frame #0. break - - -if __name__ == '__main__': - import atexit - lldb.SBDebugger.Initialize() - atexit.register(lambda: lldb.SBDebugger.Terminate()) - unittest2.main() diff --git a/lldb/test/python_api/lldbutil/process/TestPrintStackTraces.py b/lldb/test/python_api/lldbutil/process/TestPrintStackTraces.py index 09945f5cbe5..7319ce39b48 100644 --- a/lldb/test/python_api/lldbutil/process/TestPrintStackTraces.py +++ b/lldb/test/python_api/lldbutil/process/TestPrintStackTraces.py @@ -2,9 +2,10 @@ Test SBprocess and SBThread APIs with printing of the stack traces using lldbutil. """ +import lldb_shared + import os, time import re -import unittest2 import lldb from lldbtest import * @@ -47,10 +48,3 @@ class ThreadsStackTracesTestCase(TestBase): stacktraces = lldbutil.print_stacktraces(process, string_buffer=True) self.expect(stacktraces, exe=False, substrs = ['(int)argc=3']) - - -if __name__ == '__main__': - import atexit - lldb.SBDebugger.Initialize() - atexit.register(lambda: lldb.SBDebugger.Terminate()) - unittest2.main() |