From aafd552a1e9dc970ee5414cd6dd668a9da1188c3 Mon Sep 17 00:00:00 2001 From: curo1305 Date: Sat, 30 May 2026 11:43:48 +0200 Subject: [PATCH] fix(05-09): set storage_backend='minio' in test_celery_task_uses_user_provider Cloud-aware routing added in 05-09 checks doc.storage_backend; MagicMock attribute is truthy and != 'minio', so the test was entering the cloud branch without any mock for get_storage_backend_for_document. Regression: test passed before 05-09 when _run() had no cloud routing. Co-Authored-By: Claude Sonnet 4.6 --- backend/tests/test_classifier.py | 1 + 1 file changed, 1 insertion(+) diff --git a/backend/tests/test_classifier.py b/backend/tests/test_classifier.py index 33e555a..06c7a87 100644 --- a/backend/tests/test_classifier.py +++ b/backend/tests/test_classifier.py @@ -184,6 +184,7 @@ async def test_celery_task_uses_user_provider(db_session): mock_doc.content_type = "text/plain" mock_doc.extracted_text = "" mock_doc.status = "uploaded" + mock_doc.storage_backend = "minio" mock_user = MagicMock() mock_user.ai_provider = "anthropic"