feat: requires OAuth-only auth mode for MCP agents

This commit is contained in:
Anton
2026-04-29 15:08:18 +03:00
parent ad0b15cc6e
commit d20b4f396b
6 changed files with 31 additions and 17 deletions

View File

@@ -1,3 +1,6 @@
import pytest
from pydantic import ValidationError
from app.config import Settings
@@ -11,3 +14,8 @@ def test_numeric_crawl_limit_is_parsed():
settings = Settings(crawl_limit="25")
assert settings.crawl_limit == 25
def test_mcp_auth_mode_rejects_oauth_or_token_fallback():
with pytest.raises(ValidationError):
Settings(mcp_auth_mode="oauth_or_token")