MCPcopy Create free account
hub / github.com/OpenPipe/OpenPipe / test_sync_content

Function test_sync_content

client-libs/python/openpipe/test_sync_client.py:40–57  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

38
39
40def test_sync_content():
41 completion = client.chat.completions.create(
42 model="gpt-3.5-turbo",
43 messages=[{"role": "system", "content": "count to 3"}],
44 openpipe={"tags": {"prompt_id": "test_sync_content"}},
45 )
46
47 if not TEST_LAST_LOGGED:
48 return
49
50 last_logged = (
51 client.openpipe_reporting_client.base_client.local_testing_only_get_latest_logged_call()
52 )
53 assert last_logged.req_payload["messages"][0]["content"] == "count to 3"
54 assert (
55 last_logged.resp_payload["choices"][0]["message"]["content"]
56 == completion.choices[0].message.content
57 )
58
59
60def test_sync_content_mistral():

Callers

nothing calls this directly

Calls 2

createMethod · 0.45

Tested by

no test coverage detected