From fedd58462bdedbfe5938bae96e96d13a0b201318 Mon Sep 17 00:00:00 2001 From: Gauri Nagavkar Date: Sun, 15 Feb 2026 07:34:08 -0800 Subject: [PATCH] Add test for gpt-5-search-api config --- tests/test_model_config.py | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 tests/test_model_config.py diff --git a/tests/test_model_config.py b/tests/test_model_config.py new file mode 100644 index 00000000000..200cb6a3dd3 --- /dev/null +++ b/tests/test_model_config.py @@ -0,0 +1,23 @@ +import pytest +import json + +def test_gpt_5_search_api_config(): + """Test that gpt-5-search-api model is properly configured""" + with open('model_prices_and_context_window.json', 'r') as f: + config = json.load(f) + + model = config.get('gpt-5-search-api') + + # Check model exists + assert model is not None, "gpt-5-search-api not found in config" + + # Check required fields + assert model['litellm_provider'] == 'openai' + assert model['input_cost_per_token'] == 1.25e-06 + assert model['output_cost_per_token'] == 1e-05 + assert model['max_input_tokens'] == 400000 + assert model['max_output_tokens'] == 128000 + assert model['mode'] == 'chat' + assert model['supports_function_calling'] == True + + print("✅ gpt-5-search-api config is valid!")