9
9
10
10
from contextual import ContextualAI , AsyncContextualAI
11
11
from tests .utils import assert_matches_type
12
- from contextual .types .applications import QueryStartResponse
12
+ from contextual .types .applications import QueryResponse
13
13
14
14
base_url = os .environ .get ("TEST_API_BASE_URL" , "http://127.0.0.1:4010" )
15
15
@@ -85,7 +85,7 @@ def test_method_start(self, client: ContextualAI) -> None:
85
85
}
86
86
],
87
87
)
88
- assert_matches_type (QueryStartResponse , query , path = ["response" ])
88
+ assert_matches_type (QueryResponse , query , path = ["response" ])
89
89
90
90
@parametrize
91
91
def test_method_start_with_all_params (self , client : ContextualAI ) -> None :
@@ -102,7 +102,7 @@ def test_method_start_with_all_params(self, client: ContextualAI) -> None:
102
102
model_id = "model_id" ,
103
103
stream = True ,
104
104
)
105
- assert_matches_type (QueryStartResponse , query , path = ["response" ])
105
+ assert_matches_type (QueryResponse , query , path = ["response" ])
106
106
107
107
@parametrize
108
108
def test_raw_response_start (self , client : ContextualAI ) -> None :
@@ -119,7 +119,7 @@ def test_raw_response_start(self, client: ContextualAI) -> None:
119
119
assert response .is_closed is True
120
120
assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
121
121
query = response .parse ()
122
- assert_matches_type (QueryStartResponse , query , path = ["response" ])
122
+ assert_matches_type (QueryResponse , query , path = ["response" ])
123
123
124
124
@parametrize
125
125
def test_streaming_response_start (self , client : ContextualAI ) -> None :
@@ -136,7 +136,7 @@ def test_streaming_response_start(self, client: ContextualAI) -> None:
136
136
assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
137
137
138
138
query = response .parse ()
139
- assert_matches_type (QueryStartResponse , query , path = ["response" ])
139
+ assert_matches_type (QueryResponse , query , path = ["response" ])
140
140
141
141
assert cast (Any , response .is_closed ) is True
142
142
@@ -225,7 +225,7 @@ async def test_method_start(self, async_client: AsyncContextualAI) -> None:
225
225
}
226
226
],
227
227
)
228
- assert_matches_type (QueryStartResponse , query , path = ["response" ])
228
+ assert_matches_type (QueryResponse , query , path = ["response" ])
229
229
230
230
@parametrize
231
231
async def test_method_start_with_all_params (self , async_client : AsyncContextualAI ) -> None :
@@ -242,7 +242,7 @@ async def test_method_start_with_all_params(self, async_client: AsyncContextualA
242
242
model_id = "model_id" ,
243
243
stream = True ,
244
244
)
245
- assert_matches_type (QueryStartResponse , query , path = ["response" ])
245
+ assert_matches_type (QueryResponse , query , path = ["response" ])
246
246
247
247
@parametrize
248
248
async def test_raw_response_start (self , async_client : AsyncContextualAI ) -> None :
@@ -259,7 +259,7 @@ async def test_raw_response_start(self, async_client: AsyncContextualAI) -> None
259
259
assert response .is_closed is True
260
260
assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
261
261
query = await response .parse ()
262
- assert_matches_type (QueryStartResponse , query , path = ["response" ])
262
+ assert_matches_type (QueryResponse , query , path = ["response" ])
263
263
264
264
@parametrize
265
265
async def test_streaming_response_start (self , async_client : AsyncContextualAI ) -> None :
@@ -276,7 +276,7 @@ async def test_streaming_response_start(self, async_client: AsyncContextualAI) -
276
276
assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
277
277
278
278
query = await response .parse ()
279
- assert_matches_type (QueryStartResponse , query , path = ["response" ])
279
+ assert_matches_type (QueryResponse , query , path = ["response" ])
280
280
281
281
assert cast (Any , response .is_closed ) is True
282
282
0 commit comments