1010from tests .utils import assert_matches_type
1111from beeper_desktop_api import BeeperDesktop , AsyncBeeperDesktop
1212from beeper_desktop_api .types import (
13+ MessageListResponse ,
1314 MessageSendResponse ,
1415)
1516from beeper_desktop_api ._utils import parse_datetime
16- from beeper_desktop_api .pagination import SyncCursorList , AsyncCursorList , SyncCursorSearch , AsyncCursorSearch
17+ from beeper_desktop_api .pagination import SyncCursorSearch , AsyncCursorSearch
1718from beeper_desktop_api .types .shared import Message
1819
1920base_url = os .environ .get ("TEST_API_BASE_URL" , "http://127.0.0.1:4010" )
@@ -27,7 +28,7 @@ def test_method_list(self, client: BeeperDesktop) -> None:
2728 message = client .messages .list (
2829 chat_id = "!NCdzlIaMjZUmvmvyHU:beeper.com" ,
2930 )
30- assert_matches_type (SyncCursorList [ Message ] , message , path = ["response" ])
31+ assert_matches_type (MessageListResponse , message , path = ["response" ])
3132
3233 @parametrize
3334 def test_method_list_with_all_params (self , client : BeeperDesktop ) -> None :
@@ -36,7 +37,7 @@ def test_method_list_with_all_params(self, client: BeeperDesktop) -> None:
3637 cursor = "821744079" ,
3738 direction = "before" ,
3839 )
39- assert_matches_type (SyncCursorList [ Message ] , message , path = ["response" ])
40+ assert_matches_type (MessageListResponse , message , path = ["response" ])
4041
4142 @parametrize
4243 def test_raw_response_list (self , client : BeeperDesktop ) -> None :
@@ -47,7 +48,7 @@ def test_raw_response_list(self, client: BeeperDesktop) -> None:
4748 assert response .is_closed is True
4849 assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
4950 message = response .parse ()
50- assert_matches_type (SyncCursorList [ Message ] , message , path = ["response" ])
51+ assert_matches_type (MessageListResponse , message , path = ["response" ])
5152
5253 @parametrize
5354 def test_streaming_response_list (self , client : BeeperDesktop ) -> None :
@@ -58,7 +59,7 @@ def test_streaming_response_list(self, client: BeeperDesktop) -> None:
5859 assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
5960
6061 message = response .parse ()
61- assert_matches_type (SyncCursorList [ Message ] , message , path = ["response" ])
62+ assert_matches_type (MessageListResponse , message , path = ["response" ])
6263
6364 assert cast (Any , response .is_closed ) is True
6465
@@ -112,9 +113,7 @@ def test_streaming_response_search(self, client: BeeperDesktop) -> None:
112113
113114 @parametrize
114115 def test_method_send (self , client : BeeperDesktop ) -> None :
115- message = client .messages .send (
116- chat_id = "!NCdzlIaMjZUmvmvyHU:beeper.com" ,
117- )
116+ message = client .messages .send ()
118117 assert_matches_type (MessageSendResponse , message , path = ["response" ])
119118
120119 @parametrize
@@ -128,9 +127,7 @@ def test_method_send_with_all_params(self, client: BeeperDesktop) -> None:
128127
129128 @parametrize
130129 def test_raw_response_send (self , client : BeeperDesktop ) -> None :
131- response = client .messages .with_raw_response .send (
132- chat_id = "!NCdzlIaMjZUmvmvyHU:beeper.com" ,
133- )
130+ response = client .messages .with_raw_response .send ()
134131
135132 assert response .is_closed is True
136133 assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
@@ -139,9 +136,7 @@ def test_raw_response_send(self, client: BeeperDesktop) -> None:
139136
140137 @parametrize
141138 def test_streaming_response_send (self , client : BeeperDesktop ) -> None :
142- with client .messages .with_streaming_response .send (
143- chat_id = "!NCdzlIaMjZUmvmvyHU:beeper.com" ,
144- ) as response :
139+ with client .messages .with_streaming_response .send () as response :
145140 assert not response .is_closed
146141 assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
147142
@@ -161,7 +156,7 @@ async def test_method_list(self, async_client: AsyncBeeperDesktop) -> None:
161156 message = await async_client .messages .list (
162157 chat_id = "!NCdzlIaMjZUmvmvyHU:beeper.com" ,
163158 )
164- assert_matches_type (AsyncCursorList [ Message ] , message , path = ["response" ])
159+ assert_matches_type (MessageListResponse , message , path = ["response" ])
165160
166161 @parametrize
167162 async def test_method_list_with_all_params (self , async_client : AsyncBeeperDesktop ) -> None :
@@ -170,7 +165,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncBeeperDeskto
170165 cursor = "821744079" ,
171166 direction = "before" ,
172167 )
173- assert_matches_type (AsyncCursorList [ Message ] , message , path = ["response" ])
168+ assert_matches_type (MessageListResponse , message , path = ["response" ])
174169
175170 @parametrize
176171 async def test_raw_response_list (self , async_client : AsyncBeeperDesktop ) -> None :
@@ -181,7 +176,7 @@ async def test_raw_response_list(self, async_client: AsyncBeeperDesktop) -> None
181176 assert response .is_closed is True
182177 assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
183178 message = await response .parse ()
184- assert_matches_type (AsyncCursorList [ Message ] , message , path = ["response" ])
179+ assert_matches_type (MessageListResponse , message , path = ["response" ])
185180
186181 @parametrize
187182 async def test_streaming_response_list (self , async_client : AsyncBeeperDesktop ) -> None :
@@ -192,7 +187,7 @@ async def test_streaming_response_list(self, async_client: AsyncBeeperDesktop) -
192187 assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
193188
194189 message = await response .parse ()
195- assert_matches_type (AsyncCursorList [ Message ] , message , path = ["response" ])
190+ assert_matches_type (MessageListResponse , message , path = ["response" ])
196191
197192 assert cast (Any , response .is_closed ) is True
198193
@@ -246,9 +241,7 @@ async def test_streaming_response_search(self, async_client: AsyncBeeperDesktop)
246241
247242 @parametrize
248243 async def test_method_send (self , async_client : AsyncBeeperDesktop ) -> None :
249- message = await async_client .messages .send (
250- chat_id = "!NCdzlIaMjZUmvmvyHU:beeper.com" ,
251- )
244+ message = await async_client .messages .send ()
252245 assert_matches_type (MessageSendResponse , message , path = ["response" ])
253246
254247 @parametrize
@@ -262,9 +255,7 @@ async def test_method_send_with_all_params(self, async_client: AsyncBeeperDeskto
262255
263256 @parametrize
264257 async def test_raw_response_send (self , async_client : AsyncBeeperDesktop ) -> None :
265- response = await async_client .messages .with_raw_response .send (
266- chat_id = "!NCdzlIaMjZUmvmvyHU:beeper.com" ,
267- )
258+ response = await async_client .messages .with_raw_response .send ()
268259
269260 assert response .is_closed is True
270261 assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
@@ -273,9 +264,7 @@ async def test_raw_response_send(self, async_client: AsyncBeeperDesktop) -> None
273264
274265 @parametrize
275266 async def test_streaming_response_send (self , async_client : AsyncBeeperDesktop ) -> None :
276- async with async_client .messages .with_streaming_response .send (
277- chat_id = "!NCdzlIaMjZUmvmvyHU:beeper.com" ,
278- ) as response :
267+ async with async_client .messages .with_streaming_response .send () as response :
279268 assert not response .is_closed
280269 assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
281270
0 commit comments