Skip to content

Commit aad7874

Browse files
committed
[lldb][test][NFC] TestBreakpointSetRestart.py: split up assertion to determine which check specifically fails in CI
This test consistently fails on the public macOS ASAN CI (and isn't reproducible locally): ``` FAIL: test_breakpoint_set_restart_dwarf (TestBreakpointSetRestart.BreakpointSetRestart) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/ec2-user/jenkins/workspace/llvm.org/lldb-cmake-sanitized/llvm-project/lldb/packages/Python/lldbsuite/test/lldbtest.py", line 1756, in test_method return attrvalue(self) File "/Users/ec2-user/jenkins/workspace/llvm.org/lldb-cmake-sanitized/llvm-project/lldb/packages/Python/lldbsuite/test/decorators.py", line 150, in wrapper return func(*args, **kwargs) File "/Users/ec2-user/jenkins/workspace/llvm.org/lldb-cmake-sanitized/llvm-project/lldb/test/API/functionalities/breakpoint/breakpoint_set_restart/TestBreakpointSetRestart.py", line 36, in test_breakpoint_set_restart self.assertTrue(bp.IsValid() and bp.GetNumLocations() == 1, VALID_BREAKPOINT) AssertionError: False is not true : Got a valid breakpoint ``` From this error we're not quite sure what about the breakpoint here is the problem. This patch splits up the assertion to narrow down the issue.
1 parent 6b7b05b commit aad7874

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lldb/test/API/functionalities/breakpoint/breakpoint_set_restart/TestBreakpointSetRestart.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,8 @@ def test_breakpoint_set_restart(self):
3333
bp = target.BreakpointCreateBySourceRegex(
3434
self.BREAKPOINT_TEXT, lldb.SBFileSpec("main.cpp")
3535
)
36-
self.assertTrue(bp.IsValid() and bp.GetNumLocations() == 1, VALID_BREAKPOINT)
36+
self.assertTrue(bp.IsValid(), VALID_BREAKPOINT)
37+
self.assertEqual(bp.GetNumLocations(), 1, VALID_BREAKPOINT)
3738

3839
while self.dbg.GetListener().WaitForEvent(2, event):
3940
if lldb.SBProcess.GetStateFromEvent(

0 commit comments

Comments
 (0)