示例#1
0
文件: test_ctx.py 项目: tharvik/quart
def test_copy_current_request_context_error() -> None:
    with pytest.raises(RuntimeError):
        copy_current_request_context(lambda: None)()
示例#2
0
def flash(*args: Any, **kwargs: Any) -> None:
    asyncio.get_event_loop().sync_wait(  # type: ignore
        copy_current_request_context(quart_flash)(*args, **kwargs), )