Skip to content

The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]

fix(tests): use absolute path for model_prices JSON in validation test

Julio Quinteros Pro11a774e1103e
diff --git a/tests/test_litellm/test_utils.py b/tests/test_litellm/test_utils.py
index 984c6b01176..35cb290fccd 100644
--- a/tests/test_litellm/test_utils.py
+++ b/tests/test_litellm/test_utils.py
@@ -808,8 +808,7 @@ def test_aaamodel_prices_and_context_window_json_is_valid():
},
}
- prod_json = "litellm/model_prices_and_context_window.json"
- # prod_json = "../../model_prices_and_context_window.json"
+ prod_json = os.path.join(os.path.dirname(__file__), "..", "..", "model_prices_and_context_window.json")
with open(prod_json, "r") as model_prices_file:
actual_json = json.load(model_prices_file)
assert isinstance(actual_json, dict)