test(together_ai): drop the prefix-strip assertion, e2e covers it live

tests/e2e/llm_translation/test_together_ai_e2e.py registers its model with the
full registry key, so a slashed together_ai/<vendor>/<model> goes through the
prefix strip on every e2e run and an over-strip would fail against the real
API. The unit assertion was a second copy of that. The roles check stays, since
nothing in e2e exercises it.
This commit is contained in:
Yuneng Jiang 2026-09-16 13:58:38 -07:00
parent 27020c6d37
commit f10d95fb95
No known key found for this signature in database

View file

@ -1137,21 +1137,6 @@ def _together_chat_transport() -> tuple[HTTPHandler, list[httpx.Request]]:
return client, captured_requests
def test_only_the_provider_prefix_is_stripped_from_a_slashed_model_name():
client, captured_requests = _together_chat_transport()
litellm.completion(
model=f"together_ai/{TOOL_CALLING_MODEL}",
messages=[{"role": "user", "content": "Hello!"}],
api_key="fake-key",
client=client,
)
assert "/" in TOOL_CALLING_MODEL
assert str(captured_requests[0].url) == "https://api.together.ai/v1/chat/completions"
assert json.loads(captured_requests[0].content)["model"] == TOOL_CALLING_MODEL
def test_custom_role_wrappers_never_reach_the_request():
client, captured_requests = _together_chat_transport()
messages = [{"role": "user", "content": "Hello!"}]