quart.typing module#
- class quart.typing.TestAppProtocol(app: Quart)#
Bases:
Protocol
- async shutdown() None #
- async startup() None #
- test_client() TestClientProtocol #
- class quart.typing.TestClientProtocol(app: Quart, use_cookies: bool = True)#
Bases:
Protocol
- cookie_jar: CookieJar | None#
- delete_cookie(server_name: str, key: str, path: str = '/', domain: str | None = None) None #
- http_connection_class: type[TestHTTPConnectionProtocol]#
- async open(path: str, *, method: str = 'GET', headers: dict | Headers | None = None, data: AnyStr | None = None, form: dict | None = None, files: dict[str, FileStorage] | None = None, query_string: dict | None = None, json: Any, scheme: str = 'http', follow_redirects: bool = False, root_path: str = '', http_version: str = '1.1', scope_base: dict | None = None, auth: Authorization | tuple[str, str] | None = None, subdomain: str | None = None) Response #
- push_promises: list[tuple[str, Headers]]#
- request(path: str, *, method: str = 'GET', headers: dict | Headers | None = None, query_string: dict | None = None, scheme: str = 'http', root_path: str = '', http_version: str = '1.1', scope_base: dict | None = None, auth: Authorization | tuple[str, str] | None = None, subdomain: str | None = None) TestHTTPConnectionProtocol #
- session_transaction(path: str = '/', *, method: str = 'GET', headers: dict | Headers | None = None, query_string: dict | None = None, scheme: str = 'http', data: AnyStr | None = None, form: dict | None = None, json: Any = None, root_path: str = '', http_version: str = '1.1') AsyncContextManager[SessionMixin] #
- set_cookie(server_name: str, key: str, value: str = '', max_age: int | timedelta | None = None, expires: int | float | datetime | None = None, path: str = '/', domain: str | None = None, secure: bool = False, httponly: bool = False, samesite: str = None, charset: str = 'utf-8') None #
- websocket(path: str, *, headers: dict | Headers | None = None, query_string: dict | None = None, scheme: str = 'ws', subprotocols: list[str] | None = None, root_path: str = '', http_version: str = '1.1', scope_base: dict | None = None, auth: Authorization | tuple[str, str] | None = None, subdomain: str | None = None) TestWebsocketConnectionProtocol #
- websocket_connection_class: type[TestWebsocketConnectionProtocol]#