From d1ebac74a177d8757bf503d37b04aa06fd930a5c Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Mon, 16 Mar 2026 22:54:09 +0000 Subject: [PATCH] Changes before error encountered Co-authored-by: christianlouis <361235+christianlouis@users.noreply.github.com> --- tests/test_automation.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/test_automation.py b/tests/test_automation.py index 78d14bc3..6f35d8a8 100644 --- a/tests/test_automation.py +++ b/tests/test_automation.py @@ -415,7 +415,9 @@ class TestAutomationAPI: "/api/automation/actions/upload", files={"file": ("", b"content", "application/pdf")}, ) - # FastAPI/Starlette returns 422 for invalid multipart form data + # FastAPI/Starlette may return 422 (multipart validation) or 400 + # (our explicit check) depending on how the empty filename is + # parsed by the underlying multipart parser version. assert resp.status_code in (400, 422) # ── Auth required ────────────────────────────────────────────────