async def METHOD_NAME(app):
    class MySanicDb:
        pass
    @app.listener("before_server_start")
    async def init_db(app, loop):
        app.ctx.db = MySanicDb()
    srv = await app.create_server(
        debug=True, return_asyncio_server=True, port=PORT
    )
    await srv.startup()
    await srv.before_start()
    assert hasattr(app.ctx, "db")
    assert isinstance(app.ctx.db, MySanicDb)