@@ -40,37 +40,9 @@ async def test_agent_create_basic(self, async_sdk_client: AsyncRunloopSDK) -> No
4040 assert info .id == agent .id
4141 assert info .name == name
4242 finally :
43- # Agents don't have a delete method, they're managed by the API
44- pass
45-
46- @pytest .mark .timeout (THIRTY_SECOND_TIMEOUT )
47- async def test_agent_create_with_metadata (self , async_sdk_client : AsyncRunloopSDK ) -> None :
48- """Test creating an agent with metadata."""
49- name = unique_name ("sdk-async-agent-metadata" )
50- metadata = {
51- "purpose" : "sdk-testing" ,
52- "version" : "1.0" ,
53- }
54-
55- agent = await async_sdk_client .agent .create (
56- name = name ,
57- metadata = metadata ,
58- source = {
59- "type" : "npm" ,
60- "npm" : {
61- "package_name" : "@runloop/hello-world-agent" ,
62- },
63- },
64- )
65-
66- try :
67- assert agent .id is not None
68-
69- # Verify metadata is preserved
70- info = await agent .get_info ()
71- assert info .name == name
72- # Note: Metadata handling may vary based on API implementation
73- finally :
43+ # TODO: Add agent cleanup once delete endpoint is implemented
44+ # Currently agents don't have a delete method - they persist after tests
45+ # Once implemented, add: await agent.delete()
7446 pass
7547
7648 @pytest .mark .timeout (THIRTY_SECOND_TIMEOUT )
@@ -95,6 +67,7 @@ async def test_agent_get_info(self, async_sdk_client: AsyncRunloopSDK) -> None:
9567 assert info .create_time_ms > 0
9668 assert isinstance (info .is_public , bool )
9769 finally :
70+ # TODO: Add agent cleanup once delete endpoint is implemented
9871 pass
9972
10073
@@ -133,6 +106,7 @@ async def test_get_agent_by_id(self, async_sdk_client: AsyncRunloopSDK) -> None:
133106 info = await retrieved .get_info ()
134107 assert info .id == created .id
135108 finally :
109+ # TODO: Add agent cleanup once delete endpoint is implemented
136110 pass
137111
138112 @pytest .mark .timeout (THIRTY_SECOND_TIMEOUT )
@@ -163,37 +137,14 @@ async def test_list_multiple_agents(self, async_sdk_client: AsyncRunloopSDK) ->
163137 assert agent2 .id in agent_ids
164138 assert agent3 .id in agent_ids
165139 finally :
140+ # TODO: Add agent cleanup once delete endpoint is implemented
141+ # Should delete: agent1, agent2, agent3
166142 pass
167143
168144
169145class TestAsyncAgentCreationVariations :
170146 """Test different async agent creation scenarios."""
171147
172- @pytest .mark .timeout (THIRTY_SECOND_TIMEOUT )
173- async def test_agent_with_is_public_flag (self , async_sdk_client : AsyncRunloopSDK ) -> None :
174- """Test creating an agent with is_public flag."""
175- name = unique_name ("sdk-async-agent-public" )
176-
177- # Create a public agent
178- agent = await async_sdk_client .agent .create (
179- name = name ,
180- is_public = True ,
181- source = {
182- "type" : "npm" ,
183- "npm" : {
184- "package_name" : "@runloop/hello-world-agent" ,
185- },
186- },
187- )
188-
189- try :
190- assert agent .id is not None
191- info = await agent .get_info ()
192- assert info .name == name
193- assert info .is_public is True
194- finally :
195- pass
196-
197148 @pytest .mark .timeout (THIRTY_SECOND_TIMEOUT )
198149 async def test_agent_with_source_npm (self , async_sdk_client : AsyncRunloopSDK ) -> None :
199150 """Test creating an agent with npm source."""
@@ -216,6 +167,7 @@ async def test_agent_with_source_npm(self, async_sdk_client: AsyncRunloopSDK) ->
216167 assert info .source is not None
217168 assert info .source .type == "npm"
218169 finally :
170+ # TODO: Add agent cleanup once delete endpoint is implemented
219171 pass
220172
221173 @pytest .mark .timeout (THIRTY_SECOND_TIMEOUT )
@@ -241,4 +193,5 @@ async def test_agent_with_source_git(self, async_sdk_client: AsyncRunloopSDK) ->
241193 assert info .source is not None
242194 assert info .source .type == "git"
243195 finally :
196+ # TODO: Add agent cleanup once delete endpoint is implemented
244197 pass
0 commit comments