Skip to content

Fix test coverage for boundary error handling#3052

Merged
adamtheturtle merged 1 commit intomainfrom
adamtheturtle/cover-internal-server-error-branch
Mar 17, 2026
Merged

Fix test coverage for boundary error handling#3052
adamtheturtle merged 1 commit intomainfrom
adamtheturtle/cover-internal-server-error-branch

Conversation

@adamtheturtle
Copy link
Member

@adamtheturtle adamtheturtle commented Mar 16, 2026

Removed unnecessary guard condition in test_incorrect_no_boundary that was always true after a previous commit changed the / boundary error response from INTERNAL_SERVER_ERROR to BAD_REQUEST. Updated the test_no_boundary docstring to correctly reflect the BAD_REQUEST status code.

These changes improve test coverage by removing dead code.


Note

Low Risk
Low risk: changes are limited to test expectations/coverage for query boundary error handling and do not affect production logic.

Overview
Updates tests/mock_vws/test_query.py to always run handle_server_errors() in test_incorrect_no_boundary, removing a dead/incorrect guard that skipped error handling for some responses.

Also fixes the test_no_boundary docstring to match the current behavior that missing multipart boundaries return HTTPStatus.BAD_REQUEST (not INTERNAL_SERVER_ERROR).

Written by Cursor Bugbot for commit f132402. This will update automatically on new commits. Configure here.

Removed unnecessary guard condition that was always true after commit d7ea250 changed the */* boundary error from INTERNAL_SERVER_ERROR to BAD_REQUEST. Updated stale docstring in test_no_boundary that still referenced INTERNAL_SERVER_ERROR.

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant