Skip to content

Commit

Permalink
fix type hint for cli_runner.invoke (#5647)
Browse files Browse the repository at this point in the history
  • Loading branch information
davidism authored Nov 24, 2024
2 parents ea08f15 + 54c3f87 commit f2674c5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 2 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ Version 3.1.1

Unreleased

- Fix type hint for `cli_runner.invoke`. :issue:`5645`


Version 3.1.0
-------------
Expand Down
3 changes: 2 additions & 1 deletion src/flask/testing.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@

import werkzeug.test
from click.testing import CliRunner
from click.testing import Result
from werkzeug.test import Client
from werkzeug.wrappers import Request as BaseRequest

Expand Down Expand Up @@ -273,7 +274,7 @@ def __init__(self, app: Flask, **kwargs: t.Any) -> None:

def invoke( # type: ignore
self, cli: t.Any = None, args: t.Any = None, **kwargs: t.Any
) -> t.Any:
) -> Result:
"""Invokes a CLI command in an isolated environment. See
:meth:`CliRunner.invoke <click.testing.CliRunner.invoke>` for
full method documentation. See :ref:`testing-cli` for examples.
Expand Down

0 comments on commit f2674c5

Please sign in to comment.