Some extra return type added.
This commit is contained in:
parent
c7da8c2aa3
commit
8a13137e81
8 changed files with 11 additions and 11 deletions
|
|
@ -45,7 +45,7 @@ def runner(app):
|
|||
|
||||
|
||||
class AuthActions:
|
||||
def __init__(self, client):
|
||||
def __init__(self, client) -> None:
|
||||
self._client = client
|
||||
|
||||
def login(self, username="test", password="test"):
|
||||
|
|
|
|||
|
|
@ -227,7 +227,7 @@ class Flask(App):
|
|||
instance_path: str | None = None,
|
||||
instance_relative_config: bool = False,
|
||||
root_path: str | None = None,
|
||||
):
|
||||
) -> None:
|
||||
super().__init__(
|
||||
import_name=import_name,
|
||||
static_url_path=static_url_path,
|
||||
|
|
|
|||
|
|
@ -183,7 +183,7 @@ class Blueprint(Scaffold):
|
|||
url_defaults: dict[str, t.Any] | None = None,
|
||||
root_path: str | None = None,
|
||||
cli_group: str | None = _sentinel, # type: ignore[assignment]
|
||||
):
|
||||
) -> None:
|
||||
super().__init__(
|
||||
import_name=import_name,
|
||||
static_folder=static_folder,
|
||||
|
|
|
|||
|
|
@ -79,7 +79,7 @@ class Scaffold:
|
|||
static_url_path: str | None = None,
|
||||
template_folder: str | os.PathLike[str] | None = None,
|
||||
root_path: str | None = None,
|
||||
):
|
||||
) -> None:
|
||||
#: The name of the package or module that this object belongs
|
||||
#: to. Do not change this once it is set by the constructor.
|
||||
self.import_name = import_name
|
||||
|
|
|
|||
|
|
@ -111,7 +111,7 @@ def limit_loader(request, monkeypatch):
|
|||
return
|
||||
|
||||
class LimitedLoader:
|
||||
def __init__(self, loader):
|
||||
def __init__(self, loader) -> None:
|
||||
self.loader = loader
|
||||
|
||||
def __getattr__(self, name):
|
||||
|
|
|
|||
|
|
@ -156,7 +156,7 @@ def test_app_ctx_globals_methods(app, app_ctx):
|
|||
|
||||
def test_custom_app_ctx_globals_class(app):
|
||||
class CustomRequestGlobals:
|
||||
def __init__(self):
|
||||
def __init__(self) -> None:
|
||||
self.spam = "eggs"
|
||||
|
||||
app.app_ctx_globals_class = CustomRequestGlobals
|
||||
|
|
|
|||
|
|
@ -266,7 +266,7 @@ def test_session_path(app, client):
|
|||
|
||||
def test_session_using_application_root(app, client):
|
||||
class PrefixPathMiddleware:
|
||||
def __init__(self, app, prefix):
|
||||
def __init__(self, app, prefix) -> None:
|
||||
self.app = app
|
||||
self.prefix = prefix
|
||||
|
||||
|
|
@ -1781,7 +1781,7 @@ def test_multi_route_rules(app, client):
|
|||
|
||||
def test_multi_route_class_views(app, client):
|
||||
class View:
|
||||
def __init__(self, app):
|
||||
def __init__(self, app) -> None:
|
||||
app.add_url_rule("/", "index", self.index)
|
||||
app.add_url_rule("/<test>/", "index", self.index)
|
||||
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ class FakePath:
|
|||
See: https://www.python.org/dev/peps/pep-0519/
|
||||
"""
|
||||
|
||||
def __init__(self, path):
|
||||
def __init__(self, path) -> None:
|
||||
self.path = path
|
||||
|
||||
def __fspath__(self):
|
||||
|
|
@ -23,7 +23,7 @@ class FakePath:
|
|||
|
||||
|
||||
class PyBytesIO:
|
||||
def __init__(self, *args, **kwargs):
|
||||
def __init__(self, *args, **kwargs) -> None:
|
||||
self._io = io.BytesIO(*args, **kwargs)
|
||||
|
||||
def __getattr__(self, name):
|
||||
|
|
@ -265,7 +265,7 @@ class TestStreaming:
|
|||
called = []
|
||||
|
||||
class Wrapper:
|
||||
def __init__(self, gen):
|
||||
def __init__(self, gen) -> None:
|
||||
self._gen = gen
|
||||
|
||||
def __iter__(self):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue