mirror of
https://github.com/fastapi/fastapi.git
synced 2026-05-19 13:57:51 -04:00
📝 Add documentation about async tests (pytest-asyncio and httpx) (#1619)
Co-authored-by: Sebastián Ramírez <tiangolo@gmail.com>
This commit is contained in:
0
tests/test_tutorial/test_async_tests/__init__.py
Normal file
0
tests/test_tutorial/test_async_tests/__init__.py
Normal file
8
tests/test_tutorial/test_async_tests/test_main.py
Normal file
8
tests/test_tutorial/test_async_tests/test_main.py
Normal file
@@ -0,0 +1,8 @@
|
||||
import pytest
|
||||
|
||||
from docs_src.async_tests.test_main import test_root
|
||||
|
||||
|
||||
@pytest.mark.asyncio
|
||||
async def test_async_testing():
|
||||
await test_root()
|
||||
Reference in New Issue
Block a user