13 lines
293 B
Python
13 lines
293 B
Python
import asyncio
|
|
from httpx import AsyncClient, ASGITransport
|
|
from fastapi import FastAPI
|
|
|
|
app = FastAPI()
|
|
|
|
async def test():
|
|
async with AsyncClient(transport=ASGITransport(app=app), base_url='http://test') as ac:
|
|
print('Success')
|
|
|
|
if __name__ == '__main__':
|
|
asyncio.run(test())
|