Test: ultimi adattamenti ai campi e agli strumenti rimossi (B)

Tolti i campi api_key dei provider nei letterali dei test, il test del tool function di
apply_patch (funzione F non portata) e i test di login --provider; i test di core, tui, cli,
exec, mcp e app-server compilano di nuovo (cargo check --tests).

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
andrea.difonzo
2026-11-17 13:15:04 +01:00
parent 05803fcbb5
commit 875a8e4d58
9 changed files with 0 additions and 135 deletions

View File

@@ -35,36 +35,3 @@ fn create_apply_patch_freeform_tool_includes_environment_id_when_requested() {
.contains("\"*** Environment ID: \" filename LF")
);
}
#[test]
fn create_apply_patch_function_tool_takes_a_single_input_string() {
let ToolSpec::Function(tool) =
create_apply_patch_function_tool(/*include_environment_id*/ false)
else {
panic!("expected function tool");
};
assert_eq!(tool.name, "apply_patch");
assert!(tool.description.contains("*** Begin Patch"));
assert!(tool.description.contains(APPLY_PATCH_LARK_GRAMMAR));
assert!(!tool.description.contains("Environment ID"));
assert_eq!(
serde_json::to_value(&tool.parameters).expect("schema serializes"),
serde_json::json!({
"type": "object",
"properties": {
"input": {
"type": "string",
"description": "The entire contents of the apply_patch command",
},
},
"required": ["input"],
"additionalProperties": false,
})
);
let ToolSpec::Function(multi_env) =
create_apply_patch_function_tool(/*include_environment_id*/ true)
else {
panic!("expected function tool");
};
assert!(multi_env.description.contains("*** Environment ID: <id>"));
}