From 77db4a855239049488e09f28c6665fdb3b51ef90 Mon Sep 17 00:00:00 2001 From: Zachary Turner Date: Thu, 22 Oct 2015 20:06:20 +0000 Subject: Update every test to import `lldb_shared`. This is necessary in order to allow third party modules to be located under lldb/third_party rather than under the test folder directly. Since we're already touching every test file anyway, we also go ahead and delete the unittest2 import and main block wherever possible. The ability to run a test as a standalone file has already been broken for some time, and if we decide we want this back, we should use unittest instead of unittest2. A few places could not have the import of unittest2 removed,because they depend on the unittest2.expectedFailure or skip decorators. Removing all those was orthogonal in spirit to the purpose of this CL, so the import of unittest2 remains in those files that were using it for its test decorators. Those can be addressed separately. llvm-svn: 251055 --- .../non-overlapping-index-variable-i/TestIndexVariable.py | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'lldb/test/functionalities/non-overlapping-index-variable-i/TestIndexVariable.py') diff --git a/lldb/test/functionalities/non-overlapping-index-variable-i/TestIndexVariable.py b/lldb/test/functionalities/non-overlapping-index-variable-i/TestIndexVariable.py index 786102eae81..7835a3733be 100644 --- a/lldb/test/functionalities/non-overlapping-index-variable-i/TestIndexVariable.py +++ b/lldb/test/functionalities/non-overlapping-index-variable-i/TestIndexVariable.py @@ -1,7 +1,8 @@ """Test evaluating expressions which ref. index variable 'i' which just goes from out of scope to in scope when stopped at the breakpoint.""" -import unittest2 +import lldb_shared + import lldb from lldbtest import * import lldbutil @@ -38,9 +39,3 @@ class NonOverlappingIndexVariableCase(TestBase): self.runCmd('expr ptr[0]->point.y') self.runCmd('expr ptr[i]->point.x') self.runCmd('expr ptr[i]->point.y') - -if __name__ == '__main__': - import atexit - lldb.SBDebugger.Initialize() - atexit.register(lambda: lldb.SBDebugger.Terminate()) - unittest2.main() -- cgit v1.2.3