summaryrefslogtreecommitdiffstats
path: root/lldb/packages/Python/lldbsuite
diff options
context:
space:
mode:
Diffstat (limited to 'lldb/packages/Python/lldbsuite')
-rw-r--r--lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/move_nearest/TestMoveNearest.py6
-rw-r--r--lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/move_nearest/main.cpp2
2 files changed, 7 insertions, 1 deletions
diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/move_nearest/TestMoveNearest.py b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/move_nearest/TestMoveNearest.py
index 16d5bc75473..b8281e9c85b 100644
--- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/move_nearest/TestMoveNearest.py
+++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/move_nearest/TestMoveNearest.py
@@ -18,6 +18,8 @@ class TestMoveNearest(TestBase):
# Find the line number to break inside main().
self.line1 = line_number('foo.h', '// !BR1')
self.line2 = line_number('foo.h', '// !BR2')
+ self.line_between = line_number('main.cpp', "// BR_Between")
+ print("BR_Between found at", self.line_between)
self.line_main = line_number('main.cpp', '// !BR_main')
def test(self):
@@ -61,3 +63,7 @@ class TestMoveNearest(TestBase):
# "return .."
lldbutil.run_break_set_by_file_and_line(self, 'main.cpp',
self.line_main+2, extra_options="-m 1")
+
+ # Make sure we don't put move the breakpoint if it is set between two functions:
+ lldbutil.run_break_set_by_file_and_line(self, 'main.cpp',
+ self.line_between, extra_options="-m 1", num_expected_locations=0)
diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/move_nearest/main.cpp b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/move_nearest/main.cpp
index c9295a5c7d3..76a22a5420f 100644
--- a/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/move_nearest/main.cpp
+++ b/lldb/packages/Python/lldbsuite/test/functionalities/breakpoint/move_nearest/main.cpp
@@ -1,7 +1,7 @@
#include "foo.h"
int call_foo2() { return foo2(); }
-
+// BR_Between
int
main() // !BR_main
{
OpenPOWER on IntegriCloud