Private
Public Access
test(ai_client): rename send_result to send in 22 remaining test files
Batch rename of 22 test files. 62 references renamed total. The full test suite is now GREEN again, matching the pre-rename baseline from Task 1.1. Pure mechanical rename. No behavior change. Files affected: test_ai_cache_tracking, test_ai_client_cli, test_ai_client_result, test_api_events, test_context_pruner, test_deepseek_provider, test_gemini_cli_* (3 files), test_gui2_mcp, test_headless_* (2 files), test_live_gui_integration_v2, test_orchestration_logic, test_phase6_engine, test_rag_integration, test_run_worker_lifecycle_abort, test_spawn_interception_v2, test_symbol_parsing, test_tier4_interceptor, test_tiered_aggregation, test_token_usage. Note: spec estimated 24 files; actual is 22 (test_deprecation_warnings no longer exists, and 1 fewer file than spec's list). Refs: conductor/tracks/send_result_to_send_20260616/
This commit is contained in:
@@ -76,17 +76,17 @@ def test_end_to_end_tier4_integration(vlogger) -> None:
|
||||
vlogger.finalize("E2E Tier 4 Integration", "PASS", "ai_client.run_tier4_analysis correctly called and results merged.")
|
||||
|
||||
def test_ai_client_passes_qa_callback() -> None:
|
||||
"""Verifies that ai_client.send_result passes the qa_callback down to the provider function."""
|
||||
"""Verifies that ai_client.send passes the qa_callback down to the provider function."""
|
||||
qa_callback = lambda x: "analysis"
|
||||
|
||||
with patch("src.ai_client._send_gemini", return_value=Result(data="ok")) as mock_send:
|
||||
ai_client.set_provider("gemini", "gemini-2.5-flash-lite")
|
||||
result = ai_client.send_result("ctx", "msg", qa_callback=qa_callback)
|
||||
result = ai_client.send("ctx", "msg", qa_callback=qa_callback)
|
||||
assert result.ok
|
||||
args, kwargs = mock_send.call_args
|
||||
# It might be passed as positional or keyword depending on how 'send_result' calls it
|
||||
# send_result() calls _send_gemini(md_content, user_message, base_dir, ..., qa_callback, ...)
|
||||
# In current impl of send_result(), it is the 7th argument after md_content, user_msg, base_dir, file_items, disc_hist, pre_tool
|
||||
# It might be passed as positional or keyword depending on how 'send' calls it
|
||||
# send() calls _send_gemini(md_content, user_message, base_dir, ..., qa_callback, ...)
|
||||
# In current impl of send(), it is the 7th argument after md_content, user_msg, base_dir, file_items, disc_hist, pre_tool
|
||||
assert args[6] == qa_callback or kwargs.get("qa_callback") == qa_callback
|
||||
|
||||
def test_gemini_provider_passes_qa_callback_to_run_script() -> None:
|
||||
|
||||
Reference in New Issue
Block a user