예제 #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), )