1616 MemoryUpdateResponse ,
1717)
1818
19+ # pyright: reportDeprecated=false
20+
1921base_url = os .environ .get ("TEST_API_BASE_URL" , "http://127.0.0.1:4010" )
2022
2123
@@ -90,26 +92,31 @@ def test_path_params_update(self, client: Supermemory) -> None:
9092 @pytest .mark .skip ()
9193 @parametrize
9294 def test_method_list (self , client : Supermemory ) -> None :
93- memory = client .memories .list ()
95+ with pytest .warns (DeprecationWarning ):
96+ memory = client .memories .list ()
97+
9498 assert_matches_type (MemoryListResponse , memory , path = ["response" ])
9599
96100 @pytest .mark .skip ()
97101 @parametrize
98102 def test_method_list_with_all_params (self , client : Supermemory ) -> None :
99- memory = client .memories .list (
100- container_tags = ["user_123" , "project_123" ],
101- filters = '{"AND":[{"key":"group","value":"jira_users","negate":false},{"filterType":"numeric","key":"timestamp","value":"1742745777","negate":false,"numericOperator":">"}]}' ,
102- limit = "10" ,
103- order = "desc" ,
104- page = "1" ,
105- sort = "createdAt" ,
106- )
103+ with pytest .warns (DeprecationWarning ):
104+ memory = client .memories .list (
105+ container_tags = ["user_123" , "project_123" ],
106+ filters = '{"AND":[{"key":"group","value":"jira_users","negate":false},{"filterType":"numeric","key":"timestamp","value":"1742745777","negate":false,"numericOperator":">"}]}' ,
107+ limit = "10" ,
108+ order = "desc" ,
109+ page = "1" ,
110+ sort = "createdAt" ,
111+ )
112+
107113 assert_matches_type (MemoryListResponse , memory , path = ["response" ])
108114
109115 @pytest .mark .skip ()
110116 @parametrize
111117 def test_raw_response_list (self , client : Supermemory ) -> None :
112- response = client .memories .with_raw_response .list ()
118+ with pytest .warns (DeprecationWarning ):
119+ response = client .memories .with_raw_response .list ()
113120
114121 assert response .is_closed is True
115122 assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
@@ -119,12 +126,13 @@ def test_raw_response_list(self, client: Supermemory) -> None:
119126 @pytest .mark .skip ()
120127 @parametrize
121128 def test_streaming_response_list (self , client : Supermemory ) -> None :
122- with client .memories .with_streaming_response .list () as response :
123- assert not response .is_closed
124- assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
129+ with pytest .warns (DeprecationWarning ):
130+ with client .memories .with_streaming_response .list () as response :
131+ assert not response .is_closed
132+ assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
125133
126- memory = response .parse ()
127- assert_matches_type (MemoryListResponse , memory , path = ["response" ])
134+ memory = response .parse ()
135+ assert_matches_type (MemoryListResponse , memory , path = ["response" ])
128136
129137 assert cast (Any , response .is_closed ) is True
130138
@@ -336,26 +344,31 @@ async def test_path_params_update(self, async_client: AsyncSupermemory) -> None:
336344 @pytest .mark .skip ()
337345 @parametrize
338346 async def test_method_list (self , async_client : AsyncSupermemory ) -> None :
339- memory = await async_client .memories .list ()
347+ with pytest .warns (DeprecationWarning ):
348+ memory = await async_client .memories .list ()
349+
340350 assert_matches_type (MemoryListResponse , memory , path = ["response" ])
341351
342352 @pytest .mark .skip ()
343353 @parametrize
344354 async def test_method_list_with_all_params (self , async_client : AsyncSupermemory ) -> None :
345- memory = await async_client .memories .list (
346- container_tags = ["user_123" , "project_123" ],
347- filters = '{"AND":[{"key":"group","value":"jira_users","negate":false},{"filterType":"numeric","key":"timestamp","value":"1742745777","negate":false,"numericOperator":">"}]}' ,
348- limit = "10" ,
349- order = "desc" ,
350- page = "1" ,
351- sort = "createdAt" ,
352- )
355+ with pytest .warns (DeprecationWarning ):
356+ memory = await async_client .memories .list (
357+ container_tags = ["user_123" , "project_123" ],
358+ filters = '{"AND":[{"key":"group","value":"jira_users","negate":false},{"filterType":"numeric","key":"timestamp","value":"1742745777","negate":false,"numericOperator":">"}]}' ,
359+ limit = "10" ,
360+ order = "desc" ,
361+ page = "1" ,
362+ sort = "createdAt" ,
363+ )
364+
353365 assert_matches_type (MemoryListResponse , memory , path = ["response" ])
354366
355367 @pytest .mark .skip ()
356368 @parametrize
357369 async def test_raw_response_list (self , async_client : AsyncSupermemory ) -> None :
358- response = await async_client .memories .with_raw_response .list ()
370+ with pytest .warns (DeprecationWarning ):
371+ response = await async_client .memories .with_raw_response .list ()
359372
360373 assert response .is_closed is True
361374 assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
@@ -365,12 +378,13 @@ async def test_raw_response_list(self, async_client: AsyncSupermemory) -> None:
365378 @pytest .mark .skip ()
366379 @parametrize
367380 async def test_streaming_response_list (self , async_client : AsyncSupermemory ) -> None :
368- async with async_client .memories .with_streaming_response .list () as response :
369- assert not response .is_closed
370- assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
381+ with pytest .warns (DeprecationWarning ):
382+ async with async_client .memories .with_streaming_response .list () as response :
383+ assert not response .is_closed
384+ assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
371385
372- memory = await response .parse ()
373- assert_matches_type (MemoryListResponse , memory , path = ["response" ])
386+ memory = await response .parse ()
387+ assert_matches_type (MemoryListResponse , memory , path = ["response" ])
374388
375389 assert cast (Any , response .is_closed ) is True
376390
0 commit comments