From 0e14b82124a599cab8d25a1d23feb492fb12c8e2 Mon Sep 17 00:00:00 2001 From: Brandon Hancock Date: Mon, 24 Feb 2025 16:02:02 -0500 Subject: [PATCH] Fix failing test --- tests/utilities/test_events.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/utilities/test_events.py b/tests/utilities/test_events.py index 49edc8666..f46b635d3 100644 --- a/tests/utilities/test_events.py +++ b/tests/utilities/test_events.py @@ -606,7 +606,7 @@ def test_llm_emits_call_failed_event(): received_events.append(event) error_message = "Simulated LLM call failure" - with patch.object(LLM, "_call_llm", side_effect=Exception(error_message)): + with patch("crewai.llm.litellm.completion", side_effect=Exception(error_message)): llm = LLM(model="gpt-4o-mini") with pytest.raises(Exception) as exc_info: llm.call("Hello, how are you?")