hussein-awala commented on code in PR #35486:
URL: https://github.com/apache/airflow/pull/35486#discussion_r1384060037
##########
tests/www/views/test_session.py:
##########
@@ -98,3 +98,11 @@ def test_check_active_user(app, user_client):
resp = user_client.get("/home")
assert resp.status_code == 302
assert "/logout" in resp.headers.get("Location")
+
+
+def test_check_deactivated_user_redirected_to_login(app, user_client):
+ user = app.appbuilder.sm.find_user(username="test_user")
+ user.active = False
+ resp = user_client.get("/home", follow_redirects=True)
+ assert resp.status_code == 200
+ assert '/login' in resp.request.url
Review Comment:
The test doesn't reproduce the problem. I tested it with the main branch,
and it passed.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]