summaryrefslogtreecommitdiffstats
path: root/lldb/test/help/TestHelp.py
diff options
context:
space:
mode:
authorJohnny Chen <johnny.chen@apple.com>2010-08-05 21:23:45 +0000
committerJohnny Chen <johnny.chen@apple.com>2010-08-05 21:23:45 +0000
commita21249597e021c197b0e9e4a59490a4159e82f2e (patch)
tree90e76fc40d58ff6b3a26612012075ac3f6615129 /lldb/test/help/TestHelp.py
parentf03cdc5d278540a4407402d7cb784837727cf8a2 (diff)
downloadbcm5719-llvm-a21249597e021c197b0e9e4a59490a4159e82f2e.tar.gz
bcm5719-llvm-a21249597e021c197b0e9e4a59490a4159e82f2e.zip
When running a single test case, lldb.SBDebugger.Terminate() is not being called
because unittest.main() calls sys.exit() before returning. Fixed by registering an exit handler for this situation. llvm-svn: 110379
Diffstat (limited to 'lldb/test/help/TestHelp.py')
-rw-r--r--lldb/test/help/TestHelp.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/lldb/test/help/TestHelp.py b/lldb/test/help/TestHelp.py
index d4947274830..6b2b7180986 100644
--- a/lldb/test/help/TestHelp.py
+++ b/lldb/test/help/TestHelp.py
@@ -36,6 +36,7 @@ class TestHelpCommand(lldbtest.TestBase):
if __name__ == '__main__':
+ import atexit
lldb.SBDebugger.Initialize()
+ atexit.register(lambda: lldb.SBDebugger.Terminate())
unittest.main()
- lldb.SBDebugger.Terminate()
OpenPOWER on IntegriCloud