nixpkgs/pkgs/development/python-modules/flask-security/fix_test_basic.patch
Florian Brandes 2bdbb27131
python312Packages.flask-security: fix test
Signed-off-by: Florian Brandes <florian.brandes@posteo.de>
2024-12-24 10:45:18 +01:00

13 lines
No EOL
591 B
Diff

diff --git a/tests/test_basic.py b/tests/test_basic.py
index d52be429..09dfa8e4 100644
--- a/tests/test_basic.py
+++ b/tests/test_basic.py
@@ -157,6 +157,8 @@ def test_authenticate_with_subdomain_next(app, client, get_message):
@pytest.mark.settings(subdomain="auth")
def test_authenticate_with_root_domain_next(app, client, get_message):
+ # As of Flask 3.1 this must be explicitly set.
+ app.subdomain_matching = True
app.config["SERVER_NAME"] = "lp.com"
app.config["SECURITY_REDIRECT_ALLOW_SUBDOMAINS"] = True
data = dict(email="matt@lp.com", password="password")