Skip to content

Commit 3c3851f

Browse files
kendalharlandkendal
and
kendal
authored
[lldb][test][x86_64][win] Split assertion in TestBreakpointConditions (#100487)
This PR splits the test assertion that verifies we're on the correct line and have the correct value of `val` to make the error message more clear. At present it just shows `Assertion error: True != False` Co-authored-by: kendal <[email protected]>
1 parent e7f9d8e commit 3c3851f

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

lldb/test/API/functionalities/breakpoint/breakpoint_conditions/TestBreakpointConditions.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -176,11 +176,15 @@ def breakpoint_conditions_python(self):
176176
thread.IsValid(),
177177
"There should be a thread stopped due to breakpoint condition",
178178
)
179+
179180
frame0 = thread.GetFrameAtIndex(0)
180181
var = frame0.FindValue("val", lldb.eValueTypeVariableArgument)
181-
self.assertTrue(
182-
frame0.GetLineEntry().GetLine() == self.line1 and var.GetValue() == "3"
182+
self.assertEqual(
183+
frame0.GetLineEntry().GetLine(),
184+
self.line1,
185+
"The debugger stopped on the correct line",
183186
)
187+
self.assertEqual(var.GetValue(), "3")
184188

185189
# The hit count for the breakpoint should be 1.
186190
self.assertEqual(breakpoint.GetHitCount(), 1)

0 commit comments

Comments
 (0)