[Lldb-commits] [lldb] [lldb-dap] Adjust the stepInTargets tests on non-intel platforms. (PR #142820)
John Harrison via lldb-commits
lldb-commits at lists.llvm.org
Wed Jun 4 10:31:52 PDT 2025
https://github.com/ashgti created https://github.com/llvm/llvm-project/pull/142820
This test is failing for me on arm64 due to the capabilities not being sent until 'configurationDone' is called.
I adjusted the test to ensure we call 'configurationDone' so the value is sent to the test correctly.
>From 0fc2c8223ecb0888c15152331474f4ffb63c142b Mon Sep 17 00:00:00 2001
From: John Harrison <harjohn at google.com>
Date: Wed, 4 Jun 2025 10:29:33 -0700
Subject: [PATCH] [lldb-dap] Adjust the stepInTargets tests on non-intel
platforms.
This test is failing for me on arm64 due to the capabilities not being sent until 'configurationDone' is called.
I adjusted the test to ensure we call 'configurationDone' so the value is sent to the test correctly.
---
.../stepInTargets/TestDAP_stepInTargets.py | 17 +++++++++++------
lldb/tools/lldb-dap/Handler/RequestHandler.h | 3 ---
2 files changed, 11 insertions(+), 9 deletions(-)
diff --git a/lldb/test/API/tools/lldb-dap/stepInTargets/TestDAP_stepInTargets.py b/lldb/test/API/tools/lldb-dap/stepInTargets/TestDAP_stepInTargets.py
index af698074f3479..333812a61bebc 100644
--- a/lldb/test/API/tools/lldb-dap/stepInTargets/TestDAP_stepInTargets.py
+++ b/lldb/test/API/tools/lldb-dap/stepInTargets/TestDAP_stepInTargets.py
@@ -89,13 +89,16 @@ def test_supported_capability_x86_arch(self):
self.assertEqual(
len(breakpoint_ids), len(bp_lines), "expect correct number of breakpoints"
)
+ # Dynamic capability is sent in 'configurationDone' which is called
+ # prior to continue.
+ self.continue_to_breakpoints(breakpoint_ids)
+
is_supported = self.dap_server.get_initialize_value(
"supportsStepInTargetsRequest"
)
- self.assertEqual(
+ self.assertTrue(
is_supported,
- True,
f"expect capability `stepInTarget` is supported with architecture {self.getArchitecture()}",
)
# clear breakpoints.
@@ -112,15 +115,17 @@ def test_supported_capability_other_archs(self):
self.assertEqual(
len(breakpoint_ids), len(bp_lines), "expect correct number of breakpoints"
)
+ # Dynamic capability is sent in 'configurationDone' which is called
+ # prior to continue.
+ self.continue_to_breakpoints(breakpoint_ids)
+
is_supported = self.dap_server.get_initialize_value(
"supportsStepInTargetsRequest"
)
- self.assertEqual(
+ self.assertFalse(
is_supported,
- False,
- f"expect capability `stepInTarget` is not supported with architecture {self.getArchitecture()}",
+ f"expect capability `stepInTarget` is supported with architecture {self.getArchitecture()}",
)
# clear breakpoints.
- self.set_source_breakpoints(source, [])
self.continue_to_exit()
diff --git a/lldb/tools/lldb-dap/Handler/RequestHandler.h b/lldb/tools/lldb-dap/Handler/RequestHandler.h
index 559929ffb21e8..14f9d462b3d1d 100644
--- a/lldb/tools/lldb-dap/Handler/RequestHandler.h
+++ b/lldb/tools/lldb-dap/Handler/RequestHandler.h
@@ -363,9 +363,6 @@ class StepInTargetsRequestHandler
public:
using RequestHandler::RequestHandler;
static llvm::StringLiteral GetCommand() { return "stepInTargets"; }
- FeatureSet GetSupportedFeatures() const override {
- return {protocol::eAdapterFeatureStepInTargetsRequest};
- }
llvm::Expected<protocol::StepInTargetsResponseBody>
Run(const protocol::StepInTargetsArguments &args) const override;
};
More information about the lldb-commits
mailing list