2 Tests calling a function by basename
6 from lldbsuite
.test
.decorators
import *
7 from lldbsuite
.test
.lldbtest
import *
8 from lldbsuite
.test
import lldbutil
11 class CallCPPFunctionTestCase(TestBase
):
14 self
.line
= line_number("main.cpp", "// breakpoint")
16 def test_with_run_command(self
):
17 """Test calling a function by basename"""
19 lldbutil
.run_to_source_breakpoint(
20 self
, "// breakpoint", lldb
.SBFileSpec("main.cpp")
23 # The stop reason of the thread should be breakpoint.
26 STOPPED_DUE_TO_BREAKPOINT
,
27 substrs
=["stopped", "stop reason = breakpoint"],
30 self
.expect_expr("a_function_to_call()", result_type
="int", result_value
="0")