fix: harden request handling, pipeline containment, and startup boundaries
This commit is contained in:
parent
2cc33a721c
commit
3555256a02
18 changed files with 656 additions and 107 deletions
13
backend/tests/test_anthropic_llm.py
Normal file
13
backend/tests/test_anthropic_llm.py
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
"""Focused tests for Anthropic response parsing."""
|
||||
|
||||
import pytest
|
||||
|
||||
from app.adapters.anthropic.llm import _RecommendationObjectParser
|
||||
from app.ports.protocols import RecommenderOutputError
|
||||
|
||||
|
||||
def test_parser_missing_object_start_raises_typed_output_error() -> None:
|
||||
parser = _RecommendationObjectParser()
|
||||
|
||||
with pytest.raises(RecommenderOutputError, match="object start position"):
|
||||
parser._finish_object()
|
||||
Loading…
Add table
Add a link
Reference in a new issue