aboutsummaryrefslogtreecommitdiff
path: root/lldb/test/API/python_api
diff options
context:
space:
mode:
authorAndy Yankovsky <weratt@gmail.com>2020-10-26 15:31:35 +0100
committerRaphael Isemann <teemperor@gmail.com>2020-10-26 15:44:38 +0100
commit206e8d8905035f6e9049b97c9cd8af0eaa5aa118 (patch)
tree58654b5d9c883a135d21576f153fa841e4c24e1c /lldb/test/API/python_api
parent532f3bec3e019a3e6089edf6bd21e9b9b540542b (diff)
downloadllvm-206e8d8905035f6e9049b97c9cd8af0eaa5aa118.zip
llvm-206e8d8905035f6e9049b97c9cd8af0eaa5aa118.tar.gz
llvm-206e8d8905035f6e9049b97c9cd8af0eaa5aa118.tar.bz2
Fix SBError::SetErrorToGenericError
`SBError::SetErrorToGenericError` should call `Status::SetErrorToGenericError`, not `Status::SetErrorToErrno`. Reviewed By: teemperor Differential Revision: https://reviews.llvm.org/D90151
Diffstat (limited to 'lldb/test/API/python_api')
-rw-r--r--lldb/test/API/python_api/sberror/TestSBError.py13
1 files changed, 13 insertions, 0 deletions
diff --git a/lldb/test/API/python_api/sberror/TestSBError.py b/lldb/test/API/python_api/sberror/TestSBError.py
new file mode 100644
index 0000000..aa798ba
--- /dev/null
+++ b/lldb/test/API/python_api/sberror/TestSBError.py
@@ -0,0 +1,13 @@
+"""Test the SBError APIs."""
+
+from lldbsuite.test.lldbtest import *
+
+class TestSBError(TestBase):
+
+ mydir = TestBase.compute_mydir(__file__)
+ NO_DEBUG_INFO_TESTCASE = True
+
+ def test_generic_error(self):
+ error = lldb.SBError()
+ error.SetErrorToGenericError()
+ self.assertEqual(error.GetType(), lldb.eErrorTypeGeneric)