mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-07 02:59:05 +00:00
test - delete assistants
This commit is contained in:
parent
5bf430f201
commit
3480382495
1 changed files with 8 additions and 2 deletions
|
|
@ -62,10 +62,10 @@ async def test_get_assistants(provider, sync_mode):
|
|||
@pytest.mark.parametrize("provider", ["openai"])
|
||||
@pytest.mark.parametrize(
|
||||
"sync_mode",
|
||||
[False],
|
||||
[True, False],
|
||||
)
|
||||
@pytest.mark.asyncio
|
||||
async def test_create_assistants(provider, sync_mode):
|
||||
async def test_create_delete_assistants(provider, sync_mode):
|
||||
data = {
|
||||
"custom_llm_provider": provider,
|
||||
}
|
||||
|
|
@ -85,6 +85,12 @@ async def test_create_assistants(provider, sync_mode):
|
|||
== "You are a personal math tutor. When asked a question, write and run Python code to answer the question."
|
||||
)
|
||||
assert assistant.id is not None
|
||||
|
||||
# delete the created assistant
|
||||
response = litellm.delete_assistant(
|
||||
custom_llm_provider="openai", assistant_id=assistant.id
|
||||
)
|
||||
print("Response deleting assistant", response)
|
||||
else:
|
||||
assistant = await litellm.acreate_assistants(
|
||||
custom_llm_provider="openai",
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue