test_cli_blueprints() — flask Function Reference
Architecture documentation for the test_cli_blueprints() function in test_cli.py from the flask codebase.
Entity Profile
Dependency Diagram
graph TD 670fd16f_8f61_8a18_e0cb_e85c0faf6667["test_cli_blueprints()"] 62c63da0_a9c3_ab0a_4c48_a9413eac90e3["test_cli.py"] 670fd16f_8f61_8a18_e0cb_e85c0faf6667 -->|defined in| 62c63da0_a9c3_ab0a_4c48_a9413eac90e3 cfcc1ba6_ce20_a6d4_f8cd_998cddafcbac["invoke()"] 670fd16f_8f61_8a18_e0cb_e85c0faf6667 -->|calls| cfcc1ba6_ce20_a6d4_f8cd_998cddafcbac style 670fd16f_8f61_8a18_e0cb_e85c0faf6667 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
tests/test_cli.py lines 648–688
def test_cli_blueprints(app):
"""Test blueprint commands register correctly to the application"""
custom = Blueprint("custom", __name__, cli_group="customized")
nested = Blueprint("nested", __name__)
merged = Blueprint("merged", __name__, cli_group=None)
late = Blueprint("late", __name__)
@custom.cli.command("custom")
def custom_command():
click.echo("custom_result")
@nested.cli.command("nested")
def nested_command():
click.echo("nested_result")
@merged.cli.command("merged")
def merged_command():
click.echo("merged_result")
@late.cli.command("late")
def late_command():
click.echo("late_result")
app.register_blueprint(custom)
app.register_blueprint(nested)
app.register_blueprint(merged)
app.register_blueprint(late, cli_group="late_registration")
app_runner = app.test_cli_runner()
result = app_runner.invoke(args=["customized", "custom"])
assert "custom_result" in result.output
result = app_runner.invoke(args=["nested", "nested"])
assert "nested_result" in result.output
result = app_runner.invoke(args=["merged"])
assert "merged_result" in result.output
result = app_runner.invoke(args=["late_registration", "late"])
assert "late_result" in result.output
Domain
Subdomains
Defined In
Calls
Source
Frequently Asked Questions
What does test_cli_blueprints() do?
test_cli_blueprints() is a function in the flask codebase, defined in tests/test_cli.py.
Where is test_cli_blueprints() defined?
test_cli_blueprints() is defined in tests/test_cli.py at line 648.
What does test_cli_blueprints() call?
test_cli_blueprints() calls 1 function(s): invoke.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free