From 112881cbb2177fa4f18962c987932770c59da6cb Mon Sep 17 00:00:00 2001 From: Krrish Dholakia Date: Mon, 11 Dec 2023 07:58:49 -0800 Subject: [PATCH] test(test_completion.py): assert completion cost > 0.0 --- litellm/tests/test_completion.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/litellm/tests/test_completion.py b/litellm/tests/test_completion.py index 3d8b9a1b27e..473e08599aa 100644 --- a/litellm/tests/test_completion.py +++ b/litellm/tests/test_completion.py @@ -696,11 +696,12 @@ def test_completion_azure(): print(response) cost = completion_cost(completion_response=response) + assert cost > 0.0 print("Cost for azure completion request", cost) except Exception as e: pytest.fail(f"Error occurred: {e}") -# test_completion_azure() +test_completion_azure() def test_azure_openai_ad_token(): # this tests if the azure ad token is set in the request header @@ -1013,6 +1014,7 @@ def test_completion_together_ai(): # Add any assertions here to check the response print(response) cost = completion_cost(completion_response=response) + assert cost > 0.0 print("Cost for completion call together-computer/llama-2-70b: ", f"${float(cost):.10f}") except Exception as e: pytest.fail(f"Error occurred: {e}")