repeated-test-composition
Sibling tests repeat service collaborator wiring or managed ASGI HTTP clients.
Why
Repeated assembly hides scenario differences and spreads dependency signature changes across tests.
Fix
Move shared assembly into a function-scoped fixture or typed factory fixture; keep scenario values explicit.
Examples
from httpx import AsyncClient, ASGITransport
async def test_case_0(app): async with AsyncClient( transport=ASGITransport(app=app), base_url="http://test" ) as client: assert await client.get("/")
async def test_case_1(app): async with AsyncClient( transport=ASGITransport(app=app), base_url="http://test" ) as client: assert await client.get("/")
async def test_case_2(app): async with AsyncClient( transport=ASGITransport(app=app), base_url="http://test" ) as client: assert await client.get("/")async def test_response(client): assert await client.get("/")