Skip to content

Commit 8a44cd7

Browse files
authored
[NFC][lldb-dap][test] show the expected value in the error message. (#142030)
Show the expected value in the error message so we can see the expected value without searching through the log messages. Related #141689
1 parent 2b5b8db commit 8a44cd7

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

lldb/test/API/tools/lldb-dap/optimized/TestDAP_optimized.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,14 @@ def test_optimized_variable(self):
4545
self.continue_to_breakpoints(breakpoint_ids)
4646
optimized_variable = self.dap_server.get_local_variable("argc")
4747

48-
self.assertTrue(optimized_variable["value"].startswith("<error:"))
48+
value: str = optimized_variable["value"]
49+
self.assertTrue(
50+
value.startswith("<error:"),
51+
f"expect error for value: '{value}'",
52+
)
4953
error_msg = optimized_variable["$__lldb_extensions"]["error"]
5054
self.assertTrue(
5155
("could not evaluate DW_OP_entry_value: no parent function" in error_msg)
5256
or ("variable not available" in error_msg)
5357
)
58+
self.continue_to_exit()

0 commit comments

Comments
 (0)