@@ -56,7 +56,7 @@ def test_client_default_request_default_retry_attempts
5656 openai . requester = requester
5757
5858 assert_raises ( OpenAI ::Errors ::InternalServerError ) do
59- openai . chat . completions . create ( messages : [ { content : "string" , role : :developer } ] , model : :"o3-mini " )
59+ openai . chat . completions . create ( messages : [ { content : "string" , role : :developer } ] , model : :"gpt-4.1 " )
6060 end
6161
6262 assert_equal ( 3 , requester . attempts . length )
@@ -68,7 +68,7 @@ def test_client_given_request_default_retry_attempts
6868 openai . requester = requester
6969
7070 assert_raises ( OpenAI ::Errors ::InternalServerError ) do
71- openai . chat . completions . create ( messages : [ { content : "string" , role : :developer } ] , model : :"o3-mini " )
71+ openai . chat . completions . create ( messages : [ { content : "string" , role : :developer } ] , model : :"gpt-4.1 " )
7272 end
7373
7474 assert_equal ( 4 , requester . attempts . length )
@@ -82,7 +82,7 @@ def test_client_default_request_given_retry_attempts
8282 assert_raises ( OpenAI ::Errors ::InternalServerError ) do
8383 openai . chat . completions . create (
8484 messages : [ { content : "string" , role : :developer } ] ,
85- model : :"o3-mini " ,
85+ model : :"gpt-4.1 " ,
8686 request_options : { max_retries : 3 }
8787 )
8888 end
@@ -98,7 +98,7 @@ def test_client_given_request_given_retry_attempts
9898 assert_raises ( OpenAI ::Errors ::InternalServerError ) do
9999 openai . chat . completions . create (
100100 messages : [ { content : "string" , role : :developer } ] ,
101- model : :"o3-mini " ,
101+ model : :"gpt-4.1 " ,
102102 request_options : { max_retries : 4 }
103103 )
104104 end
@@ -112,7 +112,7 @@ def test_client_retry_after_seconds
112112 openai . requester = requester
113113
114114 assert_raises ( OpenAI ::Errors ::InternalServerError ) do
115- openai . chat . completions . create ( messages : [ { content : "string" , role : :developer } ] , model : :"o3-mini " )
115+ openai . chat . completions . create ( messages : [ { content : "string" , role : :developer } ] , model : :"gpt-4.1 " )
116116 end
117117
118118 assert_equal ( 2 , requester . attempts . length )
@@ -126,7 +126,7 @@ def test_client_retry_after_date
126126
127127 assert_raises ( OpenAI ::Errors ::InternalServerError ) do
128128 Thread . current . thread_variable_set ( :time_now , Time . now )
129- openai . chat . completions . create ( messages : [ { content : "string" , role : :developer } ] , model : :"o3-mini " )
129+ openai . chat . completions . create ( messages : [ { content : "string" , role : :developer } ] , model : :"gpt-4.1 " )
130130 Thread . current . thread_variable_set ( :time_now , nil )
131131 end
132132
@@ -140,7 +140,7 @@ def test_client_retry_after_ms
140140 openai . requester = requester
141141
142142 assert_raises ( OpenAI ::Errors ::InternalServerError ) do
143- openai . chat . completions . create ( messages : [ { content : "string" , role : :developer } ] , model : :"o3-mini " )
143+ openai . chat . completions . create ( messages : [ { content : "string" , role : :developer } ] , model : :"gpt-4.1 " )
144144 end
145145
146146 assert_equal ( 2 , requester . attempts . length )
@@ -153,7 +153,7 @@ def test_retry_count_header
153153 openai . requester = requester
154154
155155 assert_raises ( OpenAI ::Errors ::InternalServerError ) do
156- openai . chat . completions . create ( messages : [ { content : "string" , role : :developer } ] , model : :"o3-mini " )
156+ openai . chat . completions . create ( messages : [ { content : "string" , role : :developer } ] , model : :"gpt-4.1 " )
157157 end
158158
159159 retry_count_headers = requester . attempts . map do
@@ -171,7 +171,7 @@ def test_omit_retry_count_header
171171 assert_raises ( OpenAI ::Errors ::InternalServerError ) do
172172 openai . chat . completions . create (
173173 messages : [ { content : "string" , role : :developer } ] ,
174- model : :"o3-mini " ,
174+ model : :"gpt-4.1 " ,
175175 request_options : { extra_headers : { "x-stainless-retry-count" => nil } }
176176 )
177177 end
@@ -191,7 +191,7 @@ def test_overwrite_retry_count_header
191191 assert_raises ( OpenAI ::Errors ::InternalServerError ) do
192192 openai . chat . completions . create (
193193 messages : [ { content : "string" , role : :developer } ] ,
194- model : :"o3-mini " ,
194+ model : :"gpt-4.1 " ,
195195 request_options : { extra_headers : { "x-stainless-retry-count" => "42" } }
196196 )
197197 end
@@ -211,7 +211,7 @@ def test_client_redirect_307
211211 assert_raises ( OpenAI ::Errors ::APIConnectionError ) do
212212 openai . chat . completions . create (
213213 messages : [ { content : "string" , role : :developer } ] ,
214- model : :"o3-mini " ,
214+ model : :"gpt-4.1 " ,
215215 request_options : { extra_headers : { } }
216216 )
217217 end
@@ -233,7 +233,7 @@ def test_client_redirect_303
233233 assert_raises ( OpenAI ::Errors ::APIConnectionError ) do
234234 openai . chat . completions . create (
235235 messages : [ { content : "string" , role : :developer } ] ,
236- model : :"o3-mini " ,
236+ model : :"gpt-4.1 " ,
237237 request_options : { extra_headers : { } }
238238 )
239239 end
@@ -252,7 +252,7 @@ def test_client_redirect_auth_keep_same_origin
252252 assert_raises ( OpenAI ::Errors ::APIConnectionError ) do
253253 openai . chat . completions . create (
254254 messages : [ { content : "string" , role : :developer } ] ,
255- model : :"o3-mini " ,
255+ model : :"gpt-4.1 " ,
256256 request_options : { extra_headers : { "authorization" => "Bearer xyz" } }
257257 )
258258 end
@@ -271,7 +271,7 @@ def test_client_redirect_auth_strip_cross_origin
271271 assert_raises ( OpenAI ::Errors ::APIConnectionError ) do
272272 openai . chat . completions . create (
273273 messages : [ { content : "string" , role : :developer } ] ,
274- model : :"o3-mini " ,
274+ model : :"gpt-4.1 " ,
275275 request_options : { extra_headers : { "authorization" => "Bearer xyz" } }
276276 )
277277 end
@@ -283,7 +283,7 @@ def test_default_headers
283283 openai = OpenAI ::Client . new ( base_url : "http://localhost:4010" , api_key : "My API Key" )
284284 requester = MockRequester . new ( 200 , { } , { } )
285285 openai . requester = requester
286- openai . chat . completions . create ( messages : [ { content : "string" , role : :developer } ] , model : :"o3-mini " )
286+ openai . chat . completions . create ( messages : [ { content : "string" , role : :developer } ] , model : :"gpt-4.1 " )
287287 headers = requester . attempts . first . fetch ( :headers )
288288
289289 refute_empty ( headers [ "accept" ] )
0 commit comments