From f033c50f9aa253daf0559d9c9a4f7dd81bc24d4f Mon Sep 17 00:00:00 2001 From: 4pmtong Date: Tue, 16 Jun 2026 22:52:53 +0800 Subject: [PATCH] test: mock browser prep in chat endpoint integration --- backend/tests/app/controller/test_chat_controller.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/backend/tests/app/controller/test_chat_controller.py b/backend/tests/app/controller/test_chat_controller.py index 137a7d00..8f9bed38 100644 --- a/backend/tests/app/controller/test_chat_controller.py +++ b/backend/tests/app/controller/test_chat_controller.py @@ -488,6 +488,10 @@ class TestChatControllerIntegration: ) as mock_step_solve, patch("app.controller.chat_controller.load_dotenv"), patch("app.controller.chat_controller.set_current_task_id"), + patch( + "app.controller.chat_controller._prepare_browser_for_request_with_timeout", + new=AsyncMock(return_value=True), + ), patch("pathlib.Path.mkdir"), patch("pathlib.Path.home", return_value=MagicMock()), ):