"""Live smoke test against the real LiteLLM proxy.""" import pytest from nisse_dev.canonical import AssistantText, StoredEvent, UserMessage from nisse_dev.config import AgentConfig from nisse_dev.llm import LiteLLMClient pytestmark = pytest.mark.integration def test_executor_model_completes_via_litellm( litellm: LiteLLMClient, live_config: AgentConfig ) -> None: events = [ StoredEvent( id=1, ts="t", event=UserMessage( text="Reply with exactly one word: pong", source="smoke-test" ), ) ] result = litellm.complete(events, tools=None, model=live_config.roles.executor) texts = [e.text for e in result if isinstance(e, AssistantText)] assert texts, f"no assistant text in {result!r}" assert "pong" in texts[0].lower()