MCPcopy
hub / github.com/promptfoo/promptfoo / close_coroutine

Method close_coroutine

src/python/persistent_wrapper_test.py:47–49  ·  view source on GitHub ↗
(coro)

Source from the content-addressed store, hash-verified

45
46 # Test async function is detected and run with asyncio.run
47 def close_coroutine(coro):
48 coro.close()
49 return "mocked_async"
50
51 with patch("asyncio.run", side_effect=close_coroutine) as mock_run:
52 result = persistent_wrapper.call_method(real_async_func, [])

Callers

nothing calls this directly

Calls 1

closeMethod · 0.65

Tested by

no test coverage detected