Skip to content

Commit d3993ac

Browse files
committed
[lldb][test] Correctly fix break at _dl_debug_state test on arm.
If lldb finds the dynamic linker in the search path or if the binary is linked staticlly, it will fail at `lldbutil.run_break_set_by_symbol` because the breakpoint is resolved. Otherwise, it's not resolved at this point. But we don't care if it's resolved or not. This test cares about if the breakpoint is hit or not after launching. This changes the num_expected_locations to -2, which means don't assert on if this breakpoint resolved or not.
1 parent 9606716 commit d3993ac

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lldb/test/API/functionalities/breakpoint/breakpoint_command/TestBreakpointCommand.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -672,7 +672,7 @@ def test_breakpoint_statistics_hitcount(self):
672672
for breakpoint_stats in breakpoints_stats:
673673
self.assertIn("hitCount", breakpoint_stats)
674674

675-
@skipIf(oslist=no_match(["linux"]), archs=["arm", "aarch64"])
675+
@skipIf(oslist=no_match(["linux"]))
676676
def test_break_at__dl_debug_state(self):
677677
"""
678678
Test lldb is able to stop at _dl_debug_state if it is set before the
@@ -682,7 +682,7 @@ def test_break_at__dl_debug_state(self):
682682
exe = self.getBuildArtifact("a.out")
683683
self.runCmd("target create %s" % exe)
684684
bpid = lldbutil.run_break_set_by_symbol(
685-
self, "_dl_debug_state", num_expected_locations=0
685+
self, "_dl_debug_state", num_expected_locations=-2
686686
)
687687
self.runCmd("run")
688688
self.assertIsNotNone(

0 commit comments

Comments
 (0)