looping chatbot with ephemeral history
This commit is contained in:
@@ -6,6 +6,7 @@ from pydantic import ValidationError
|
||||
from agent.config import Settings
|
||||
|
||||
|
||||
@pytest.mark.unit
|
||||
def test_settings_with_all_values():
|
||||
"""Test Settings loads correctly with all values provided."""
|
||||
settings = Settings(
|
||||
@@ -20,6 +21,7 @@ def test_settings_with_all_values():
|
||||
assert settings.max_tokens == 500
|
||||
|
||||
|
||||
@pytest.mark.unit
|
||||
def test_settings_defaults():
|
||||
"""Test Settings uses defaults for optional values."""
|
||||
settings = Settings(
|
||||
@@ -31,6 +33,7 @@ def test_settings_defaults():
|
||||
assert settings.max_tokens == 500
|
||||
|
||||
|
||||
@pytest.mark.unit
|
||||
def test_settings_missing_required_field():
|
||||
"""Test Settings raises error when required field is missing."""
|
||||
with pytest.raises(ValidationError) as exc_info:
|
||||
@@ -40,6 +43,7 @@ def test_settings_missing_required_field():
|
||||
assert "anthropic_api_key" in str(exc_info.value)
|
||||
|
||||
|
||||
@pytest.mark.unit
|
||||
def test_settings_type_validation():
|
||||
"""Test Settings validates types correctly."""
|
||||
with pytest.raises(ValidationError):
|
||||
|
||||
Reference in New Issue
Block a user