From 8a5ecd1632cfe088296647d94522c206f55c9f7e Mon Sep 17 00:00:00 2001 From: mikemikimike <13286568797@163.com> Date: Sat, 29 Aug 2026 18:35:07 +0800 Subject: [PATCH] test: document internal patch exceptions --- .../responses/test_responses_prompt_management.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/tests/test_litellm/responses/test_responses_prompt_management.py b/tests/test_litellm/responses/test_responses_prompt_management.py index bcf7716eb08..4f55fa9461e 100644 --- a/tests/test_litellm/responses/test_responses_prompt_management.py +++ b/tests/test_litellm/responses/test_responses_prompt_management.py @@ -13,7 +13,6 @@ Covers: I) async path propagates optional params to downstream handler """ -import asyncio from typing import List, cast from unittest.mock import AsyncMock, MagicMock, patch @@ -144,8 +143,8 @@ class TestResponsesAPIPromptManagement: prompt_manager = MagicMock() cache_hook = MagicMock(spec=AnthropicCacheControlHook) with ( - patch("litellm.litellm_core_utils.litellm_logging.litellm.logging_callback_manager") as callback_manager, - patch("litellm.litellm_core_utils.litellm_logging.AnthropicCacheControlHook") as hook_class, + patch("litellm.litellm_core_utils.litellm_logging.litellm.logging_callback_manager") as callback_manager, # test-quality-ok: isolate callback registry + patch("litellm.litellm_core_utils.litellm_logging.AnthropicCacheControlHook") as hook_class, # test-quality-ok: isolate cache hook construction ): callback_manager.get_custom_loggers_for_type.return_value = [prompt_manager] hook_class.get_custom_logger_for_anthropic_cache_control_hook.return_value = cache_hook