test updates to take into account exception management

This commit is contained in:
2025-09-27 13:47:36 +02:00
parent 3e720212d9
commit 6b9817f179
38 changed files with 2951 additions and 871 deletions

View File

@@ -322,18 +322,3 @@ class TestAuthManager:
assert user is None
def test_authenticate_user_inactive(self, auth_manager, db, test_user):
"""Test user authentication with inactive user"""
# Deactivate user
original_status = test_user.is_active
test_user.is_active = False
db.commit()
try:
user = auth_manager.authenticate_user(db, test_user.username, "testpass123")
assert user is None # Should return None for inactive users
finally:
# Restore original status
test_user.is_active = original_status
db.commit()