This commit is contained in:
@@ -193,7 +193,12 @@ def test_multi_step_timeline_records_actual_per_step_prompts(tmp_path) -> None:
|
||||
"""When AIPlanner is used, each timeline step's prompt is the real
|
||||
per-step user prompt (containing scene JSON), not the bare task goal."""
|
||||
decisions = [
|
||||
ToolCallDecision(tool_name="tap", arguments={"x": 1, "y": 2}),
|
||||
ToolCallDecision(
|
||||
tool_name="tap",
|
||||
arguments={"x": 1, "y": 2},
|
||||
purpose="Open the send control.",
|
||||
expected_outcome="The message composer is focused.",
|
||||
),
|
||||
ToolCallDecision(tool_name="finish_task", arguments={"success": True}),
|
||||
]
|
||||
client = ScriptedToolCallingClient(decisions)
|
||||
@@ -228,6 +233,12 @@ def test_multi_step_timeline_records_actual_per_step_prompts(tmp_path) -> None:
|
||||
assert "Current Scene (JSON)" in prompt
|
||||
assert "Call exactly one tool" in prompt
|
||||
assert "tap the button" in prompt
|
||||
assert records[0]["tool_call"]["args"] == {"x": 1, "y": 2}
|
||||
assert records[0]["tool_call"]["purpose"] == "Open the send control."
|
||||
assert (
|
||||
records[0]["tool_call"]["expected_outcome"]
|
||||
== "The message composer is focused."
|
||||
)
|
||||
|
||||
|
||||
def test_non_ai_planner_falls_back_to_task_goal_for_prompt(tmp_path) -> None:
|
||||
|
||||
Reference in New Issue
Block a user