remove BaseRequest and BaseResponse

This commit is contained in:
David Lord 2021-01-29 10:38:40 -08:00
parent fdba0d2526
commit 1936ca8a2e
No known key found for this signature in database
GPG key ID: 7A1C87E3F5BC42A8
5 changed files with 5 additions and 5 deletions

View file

@ -119,7 +119,7 @@ Notice that our test functions begin with the word `test`; this allows
By using ``client.get`` we can send an HTTP ``GET`` request to the By using ``client.get`` we can send an HTTP ``GET`` request to the
application with the given path. The return value will be a application with the given path. The return value will be a
:class:`~flask.Flask.response_class` object. We can now use the :class:`~flask.Flask.response_class` object. We can now use the
:attr:`~werkzeug.wrappers.BaseResponse.data` attribute to inspect :attr:`~werkzeug.wrappers.Response.data` attribute to inspect
the return value (as string) from the application. the return value (as string) from the application.
In this case, we ensure that ``'No entries here so far'`` In this case, we ensure that ``'No entries here so far'``
is part of the output. is part of the output.

View file

@ -302,7 +302,7 @@ URL when the register view redirects to the login view.
:attr:`~Response.data` contains the body of the response as bytes. If :attr:`~Response.data` contains the body of the response as bytes. If
you expect a certain value to render on the page, check that it's in you expect a certain value to render on the page, check that it's in
``data``. Bytes must be compared to bytes. If you want to compare text, ``data``. Bytes must be compared to bytes. If you want to compare text,
use :meth:`get_data(as_text=True) <werkzeug.wrappers.BaseResponse.get_data>` use :meth:`get_data(as_text=True) <werkzeug.wrappers.Response.get_data>`
instead. instead.
``pytest.mark.parametrize`` tells Pytest to run the same test function ``pytest.mark.parametrize`` tells Pytest to run the same test function

View file

@ -16,7 +16,7 @@ from werkzeug.routing import Map
from werkzeug.routing import RequestRedirect from werkzeug.routing import RequestRedirect
from werkzeug.routing import RoutingException from werkzeug.routing import RoutingException
from werkzeug.routing import Rule from werkzeug.routing import Rule
from werkzeug.wrappers import BaseResponse from werkzeug.wrappers import Response as BaseResponse
from . import cli from . import cli
from . import json from . import json

View file

@ -5,7 +5,7 @@ import werkzeug.test
from click.testing import CliRunner from click.testing import CliRunner
from werkzeug.test import Client from werkzeug.test import Client
from werkzeug.urls import url_parse from werkzeug.urls import url_parse
from werkzeug.wrappers import BaseRequest from werkzeug.wrappers import Request as BaseRequest
from . import _request_ctx_stack from . import _request_ctx_stack
from .cli import ScriptInfo from .cli import ScriptInfo

View file

@ -113,7 +113,7 @@ class Response(ResponseBase):
def max_cookie_size(self): def max_cookie_size(self):
"""Read-only view of the :data:`MAX_COOKIE_SIZE` config key. """Read-only view of the :data:`MAX_COOKIE_SIZE` config key.
See :attr:`~werkzeug.wrappers.BaseResponse.max_cookie_size` in See :attr:`~werkzeug.wrappers.Response.max_cookie_size` in
Werkzeug's docs. Werkzeug's docs.
""" """
if current_app: if current_app: