test: cover agent api base url suffix handling

This commit is contained in:
Mikhail Putilovskij 2026-04-24 12:39:50 +03:00
parent 59fbb52c20
commit 842117900a
2 changed files with 13 additions and 1 deletions

View file

@ -148,7 +148,7 @@ Matrix бот подключается к `platform-agent` по service name, а
На `2026-04-21` локальный compose runtime использует vendored upstream-версии платформы без локальных патчей:
- `platform-agent`: `5e7c2df954cc3cd2f5bf8ae688e10a20038dde61`
- `platform-agent_api`: `aa480bbec5bbf8e006284dd03aed1c2754e9bbee`
- `platform-agent_api`: `8a4f4db6d36786fe8af7feefffe506d4a54ac6bd`
### 4. Staged attachments в Matrix

View file

@ -9,6 +9,18 @@ def test_lambda_agent_api_module_is_importable():
assert AgentApi is not None
def test_lambda_agent_api_preserves_base_url_path_suffix():
from sdk.upstream_agent_api import AgentApi
api = AgentApi(
agent_id="matrix-bot",
base_url="http://platform-agent:8000/proxy/",
chat_id="chat-7",
)
assert api.url == "http://platform-agent:8000/proxy/v1/agent_ws/chat-7/"
def test_agent_session_module_is_intentionally_stubbed():
contents = Path(__file__).resolve().parents[2] / "sdk" / "agent_session.py"