require a non-empty name for blueprints

This commit is contained in:
Evgeny Mozhaev 2023-03-04 21:09:34 +03:00 committed by David Lord
parent 7ee9ceb71e
commit b8b410014d
No known key found for this signature in database
GPG key ID: 7A1C87E3F5BC42A8
3 changed files with 10 additions and 0 deletions

View file

@ -256,6 +256,11 @@ def test_dotted_name_not_allowed(app, client):
flask.Blueprint("app.ui", __name__)
def test_empty_name_not_allowed(app, client):
with pytest.raises(ValueError):
flask.Blueprint("", __name__)
def test_dotted_names_from_app(app, client):
test = flask.Blueprint("test", __name__)