forked from OSchip/llvm-project
[lldb] Remove unused and too strict error_msg parameter from expect_expr
Directly matching the error message is nearly never useful. We can re-add error-checking once we have a plan to properly implement this.
This commit is contained in:
parent
461566b046
commit
af7fc8c1bb
|
@ -2396,7 +2396,6 @@ FileCheck output:
|
|||
result_summary=None,
|
||||
result_value=None,
|
||||
result_type=None,
|
||||
error_msg=None,
|
||||
):
|
||||
"""
|
||||
Evaluates the given expression and verifies the result.
|
||||
|
@ -2404,7 +2403,6 @@ FileCheck output:
|
|||
:param result_summary: The summary that the expression should have. None if the summary should not be checked.
|
||||
:param result_value: The value that the expression should have. None if the value should not be checked.
|
||||
:param result_type: The type that the expression result should have. None if the type should not be checked.
|
||||
:param error_msg: The error message the expression should return. None if the error output should not be checked.
|
||||
"""
|
||||
self.assertTrue(expr.strip() == expr, "Expression contains trailing/leading whitespace: '" + expr + "'")
|
||||
|
||||
|
@ -2420,11 +2418,6 @@ FileCheck output:
|
|||
|
||||
eval_result = frame.EvaluateExpression(expr, options)
|
||||
|
||||
if error_msg:
|
||||
self.assertFalse(eval_result.IsValid(), "Unexpected success with result: '" + str(eval_result) + "'")
|
||||
self.assertEqual(error_msg, eval_result.GetError().GetCString())
|
||||
return
|
||||
|
||||
if not eval_result.GetError().Success():
|
||||
self.assertTrue(eval_result.GetError().Success(),
|
||||
"Unexpected failure with msg: " + eval_result.GetError().GetCString())
|
||||
|
|
Loading…
Reference in New Issue